problem with accessing a php page
Posted
by
EquinoX
on Server Fault
See other posts from Server Fault
or by EquinoX
Published on 2011-02-28T22:56:04Z
Indexed on
2011/02/28
23:26 UTC
Read the original article
Hit count: 169
So I have a info.php page which is located on the folder /var/www/nginx-default, however when I go to my ip address/info.php, it always redirects me to this site:
http://www.iana.org/domains/example/
is this because I have a virtual host that I called example? Here is my config for the example website:
server {
listen 80;
server_name www.example.com;
rewrite ^/(.*) http://example.com/$1 permanent;
}
server {
listen 80;
server_name example.com;
access_log /var/www/example.com/logs/access.log;
error_log /var/www/example.com/logs/error.log;
location / {
root /var/www/example.com/public/;
index index.html;
}
}
The way I access this site is by changing my /var/hosts in my macbook so that example.com is mapped to my server IP address... however now when I do xxx.xxx.xxx.xxx/info.php.. it redirects me to that site I posted above
© Server Fault or respective owner