If you have a website running on your computer that you typically access by visiting http://localhost, you can also access this site from your mobile phone as long as both computers are connected to the same network.


First of all you'll need to connect both devices to the same network. So make sure your mobile phone is connected to the same Wi-Fi network that your computer is using.


1 -Edit httpd.conf file of Wamp server to fix 403 error


We need to edit httpd.conf file else we will get 403 forbidden error when we access the localhost through local network ip.

1 .Click on wamp server tray icon

2. OpenApache server sub menu

3. Select httpd.conf

4 .Search for " Possible values for the Options directive are "



    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.4/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   AllowOverride FileInfo AuthConfig Limit
    #
    AllowOverride all

    #
    # Controls who can get stuff from this server.
    #

#   onlineoffline tag - don't remove
    Require local
 






add  "  Require all granted  "   under   Require local


Find your local network ip


After that you can find the IP address by visiting Control Panel. In the search box, search for "adapter". Click on View Network Connections. Select the active network connection and click View status of this connection. Click Details and the IP address should be found next to IPv4 Address.


1. open command prompt.

2 .type and enter ipconfig command.


Just type this ip on your mobile browser to display your localhost page successfully.



How do you access a website running on localhost from iPhone browser
How can I access my localhost from my Android device
Testing localhost on other devices
Accessing localhost From Anywhere
How I Test Locally Hosted Sites With Physical Devices
Remote Access to Your Local Site
Axact

Hssan Riahi

Hssan Riahi is a Web Developer, designer and a programmer.He loves experimenting with technology and codes.

Post A Comment:

0 comments: