简体   繁体   中英

Issue in accessing asp.net application aspx pages on IIS 7.5 with machine name/IP url?

I have re written a vb.net framework 2.0 application to c# .net framework 4.0.

I have hosted my new asp.net application on IIS 7.5 . The application is accessible once I hit the url as http://localhost/appname from internet explorer 8.0 . But the issue comes when I use the computer name or IP address in place of localhost in url. The User Interface of few **aspx pages are getting distorted with one page displaying with no controls**. Its just a white page appearing.

On the other hand I have the same application written in vb.net with framework 2.0. . This application is behaving fine with both way of accessing ( localhost or with machine/IP name) .

Please help regarding the hosting and accessing the new c# rewritten application??

Regards, Joshi_007

This can happen if you have subfolders in your site holding your styles etc.. are your controls user controls in a subfolder?

ensure your site's subfolders have location entries in your config...

<location path="content">
    <system.web>
        <authorization>
          <allow users="*"/>
        </authorization>
    </system.web>
</location>
<location path="images">
    <system.web>
        <authorization>
          <allow users="*"/>
        </authorization>
    </system.web>
</location>
 <location path="resources">
    <system.web>
        <authorization>
          <allow users="*"/>
        </authorization>
    </system.web>
</location>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM