什么是一个目录,从域名本身重定向到一个页面的正确方法是什么? [英] What is the correct way for redirecting from the domain name itself to a page in a directory?
问题描述
我想任何人在浏览MyDomain.com,看看有什么在MyDomain.com/Folder1/HomePage.aspx。
我尝试添加一个页面< META HTTP-当量=刷新内容=0; URL ='MyDomain.com /资料夹/ HomePage.aspx'/>
,但有一个轻微的延迟。我宁愿它被悄悄完成。
我尝试使用IIS管理器的HTTP重定向,但所有子目录继承它。 (并要求在此<一个href=\"http://stackoverflow.com/questions/13629137/$p$pvent-subdirectories-from-inheriting-an-http-redirect-in-iis\">$p$pvent子目录继承HTTP重定向(在IIS)关于解决了返回主要沉默近距离票。)
那么,如何实现呢?
的Response.Redirect
似乎是最好的办法。
I want anyone browsing for "MyDomain.com" to see what's in "MyDomain.com/Folder1/HomePage.aspx".
I tried adding a page with <meta http-equiv="refresh" content="0;URL='MyDomain.com/Folder1/HomePage.aspx'" />
but there is a slight delay. I'd rather it is done silently.
I tried using iis-manager's HTTP-Redirect, but all sub-directories inherit it. (And asking here Prevent subdirectories from inheriting an http redirect (in iis) about solving that returned mainly silent close-votes.)
So how do I achieve it?
Response.Redirect
Seems to be the best way.
这篇关于什么是一个目录,从域名本身重定向到一个页面的正确方法是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!