1

I'am a beginner FrontEnd developer. I want to build webapplication. I made in Visual Studio a asp.net project. When I build the project I can see the project is running en the chrome browser starts. But when I want to reach the localhost via Tablet of mobile phone it gaves me localhost error. I have searched on internet and there are really basics steps like you have to connect to the same wifi network and your computer should be detectable. I have done these things but nothing helps. So my quastion is how can I fix this problem?

Note: I have Jenkins installed on my computer. On my tablet if I browse to 193.0.0.0:8080 I can reach Jenkins. This means that I can connect to localhost 8080.

Can anyone tell me how I can fix this problem. Is this an issue in Visual Studio of do I have to do something in IIS?

Thanks in advance

Filburt
  • 17,626
  • 12
  • 64
  • 115
  • 1
    Do an ipconfig on your host device, take that ipadress and add:8080 to it. If that doesn't work, try getting your public ip (from an external site) and navigate to that ipadress + :8080. Note that there also might be your firewall blocking IIS output. if so try disabling it (or allowing access) – Bebolicious May 10 '19 at 11:39
  • Did you try this: https://stackoverflow.com/questions/17316692/viewing-localhost-website-from-mobile-device ? – vsarunov May 10 '19 at 11:50
  • Hi Bebolicious thank for quick response. My firewall is disconnected. But the strange thing is if I navigate to ip +:8080 Jenkins is working. And when I navigate to ip +:8081 (is the asp.net project) localhost is invalid – WilliamAshoti May 10 '19 at 11:55
  • I added an answer to with more options you can try. – Bebolicious May 10 '19 at 12:25

1 Answers1

0

There might be a few things you need to do.

  1. Allow IIS access in your firewall settings.
  2. Try accessing your server with the remote ip and port of your host. (There's a VS Exstension helping with this.
  3. Binding protocols in your applicationhost.config.

    <bindings>
     <binding protocol="http" bindingInformation="*:8080:Your local Ip"/>
    </bindings>
    

For Reference

Bebolicious
  • 116
  • 1
  • 11
  • 1
    Hi Bebolicious and the rest. To be honest I have installed the VS extension Conveyor by Keroti. And Iam able now to access the localhost from my mobile device and from tablet. But somethins is strange here. On my device latop when I run the application the local url is localhost 8081 and remote url is 45455. Can someone explain me whats the diffrence and can I change the remote URL on my device to 8081 instead of 45455? – WilliamAshoti May 11 '19 at 18:24