A case of ASP.net Web site ' This page contains redirect loops ' solution __.net

Source: Internet
Author: User

A strange problem has been encountered today;

A Web site, using the VS self-asp.net Development server startup is fine. However, you cannot access it after you start with IIS Express.

Use IE to view the site to find out what problems, using Chrome report error ' This page contains redirect loops '.


It seems to be the code somewhere wrong, check the code, login page has such a paragraph;

protected void Page_Load (object sender, EventArgs e)
    {
        formsauthentication.signout ();
        String tttt = request.querystring["ReturnUrl"];
        if (tttt!= "/luozhuang/default.aspx")
        {
            Response.Redirect ("...)". /default.aspx ", True);
        }
It appears that the problem in the access path is written dead. Because the root that IIS Express uses by default is/, the root of the ASP.net Development server setting is/luozhuang.

The solution is to set up the IIS Express;

  </site>
            <site name= "Bsim" id= "2048214810" >
                <application path= "/" applicationpool= " Clr2integratedapppool ">
                    <virtualdirectory path="/"physicalpath=" E:\luozhuang "/>
                </ application>
                 <application path= "/luozhuang" applicationpool= "Clr2integratedapppool" >
                    < VirtualDirectory path= "/" physicalpath= "E:\luozhuang"/>
                </application>
                <bindings>
                    <binding protocol= "http" bindinginformation= "*:15792:localhost"/>
                </bindings>
            </site >
And then use Http://localhost:15792/luozhuang to visit the good, hey these program ape is also let people have no language.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.