Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

So, I've been searching around on how to allow other so, not just on my LAN, to look at my server(so I can fully use this app http://www.androidhive.info/2012/05/how-to-connect-android-with-php-mysql/). But I can never seem to get it to work. And it seems that everything I find is different from the one before. Is there any place where I can find a set way to allow others to access my server? It is Wampserver (32 bits & PHP 5.4) 2.4 or could someone explain to me how.

Thank you in advance,

Tyler

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
137 views
Welcome To Ask or Share your Answers For Others

1 Answer

This really depends upon how and from where you are running your app.

If you are running out of wampwww or wampwwwa_folder then you should be able to use the Wampmanager menus ( thats the green icon that sits in the System Tray ) like so:-

wampmanager -> Put Online

Now there was a little bug in WAMPServer 2.4 that causes this menu function not to work so I suggest you have a look at this document which has a fix for this problem and suggestions for many other tidy-ups for the 2.4 release. WAMPServer 2.4 What to do after installing

Now of course you can just manually change your httpd.conf file, again using the wampmanager menus to make sure you edit the correct file.

wampmanager -> Apache -> httpd.conf

This will open the httpd.conf file in an editor, probably notepad.

Find this in that file:-

# onlineoffline tag - do not remove
Require local

And change it to

# onlineoffline tag - do not remove
Require all granted

Yours may look like this if you have not made the changes suggested in the document mentioned above.

#    Require all granted
#   onlineoffline tag - don't remove
     Order Deny,Allow
     Deny from all
     Allow from 127.0.0.1
     Allow from ::1
     Allow from localhost

But regardless change it to what is suggested above

If you have created a Virtual Host then this change can be done manually in the Virtual Host definition just the same way.

Of course once you have done that, you also need to Port Forward your router to allow traffic on Port 80 from the internet through your router and to your PC running the WAMPServer. This is quite a handy site as it contains instructions on how to do the port forwarding for lots of different routers. PortForward.com


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...