Quantcast
Channel: Nginx Forum - How to...
Viewing all articles
Browse latest Browse all 4759

SYNTAX : ~^(?.+)\.MYSITE\.com$

$
0
0
Hello everybody,
In 2012, i install nginx on vps it was working without problem under debian 6
2 weeks ago, my vps stop and my provider no more have debian 6 but 7,
so i install the new version on nginx, but old parameters dont work anymore...

How it did work : when i create a folder under /var/www it is directly accessible
like a subdomaine
for exemple;
i create /var/www/www/index.hml then in web browser i just type
http://www.MYSITE.com
i create /var/www/test/index.hml then in web browser i just type
http://test.MYSITE.com

here script that use to work :

server {
listen 80;
charset utf-8;
source_charset utf-8;

server_name ~^(?<user>.+)\.MYSITE\.com$;
root /var/www/$user;
return 301 http://~^(?<user>.+)\.MYSITE\.com$request_uri;

index index.html index.php;

}

Viewing all articles
Browse latest Browse all 4759

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>