PDA

View Full Version : Signatures rewrite for nginx


Rytis
06-26-2013, 16:34
Hi,

does someone know the correct signatures rewrite for nginx?

RewriteRule sig-(.*)-(.*).png$ sig.php?player_id=$1&background=$2 [L]

location / {
rewrite sig-(.*)-(.*).png$ /sig.php?player_id=$1&background=$2 break;
}
is not working :I

Regards,
Rytis

gH0sTy
06-27-2013, 01:27
Add this to your server block of your hlx domain config
rewrite sig-(.*)-(.*).png$ /sig.php?player_id=$1&background=$2 break;

Example:
server {
listen 80;
server_name hlstatsx.domain.com;
index index.php;

rewrite sig-(.*)-(.*).png$ /sig.php?player_id=$1&background=$2 break;
}

Rytis
06-27-2013, 08:06
Aww, I love you (no homo), it's working now :D
But shouldn't that be in location? :P