开发者

Can't access intranet webpage (wordpress running on xampp) using ip-address

I have installed xampp and wordpress on one of the PCs (Windows XP) in my office.

Currently I can access my webpage by specifying the webserver's pcname. e.g. http: //pcname

and I can't access it using the ip-address of the webserver.

Any idea on how I can access it using the ip-address e.g. http: //192.xx.xx.xx

More details:

1. I can access xampp homepage using http: //localho开发者_运维百科st/xampp/ or http: //127.0.0.1/xampp/ locally within the webserver, but can't access it by specifying its ip-address (http://192.xx.xx.xx/xampp/) locally. I can see the security page when accessing from http: //pcname/xampp/.

2. I installed wordpress in the C:\xampp\htdocs root directory and have set the "WordPress address (URL)" and "Site address (URL)" to http: //pcname from the "Settings" - "General" menu.

3. Other PC in the network can access the shared folder in the webserver (Can access the PC by specifying \pcname or \192.xx.xx.xx on Windows explorer.

4. The firewall has been disabled on the webserver.

5. The webserver has static ip-address.

Any help is appreciated.


Try this:

Stop the apache server. Open xampp\apache\conf\extra\httpd-xampp.conf in a text-editor and add/change the following at the very end:

#
# New XAMPP security concept
#

# Close XAMPP security section here 
<LocationMatch "^/(?i:(?:security))">
   Order deny,allow
   #Deny from all
   Allow from ::1 127.0.0.0/8 
   ErrorDocument 403 /error/HTTP_XAMPP_FORBIDDEN.html.var
</LocationMatch>

# Close XAMPP sites here
<LocationMatch "^/(?i:(?:xampp|licenses|phpmyadmin|webalizer|server-status|server-info))">
   Order deny,allow
   #Deny from all
   Allow from ::1 127.0.0.0/8 
   ErrorDocument 403 /error/HTTP_XAMPP_FORBIDDEN.html.var
</LocationMatch>

Restart the apache server. If this solves anything, then you must revise these security settings, because your system is now insecure. If this doesn't do anything for you, then delete it again. I can't advise you on how to revise the security settings, ask someone else for now.

2.I installed wordpress in the C:\xampp\htdocs root directory and have set the "WordPress address >(URL)" and "Site address (URL)" to http: //pcname from the "Settings" - "General" menu.

Now, if this means you are going to change the URL that Wordpress uses (from //pcname to an IP-address, then you have 2 ways of getting the wordpress to work again:
1. Reinsall from scratch.
2. Manually change all references to the old URL in all files and database.

This is my experience, anyway.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜