2017-02-28 19:21:40 +00:00
|
|
|
# replace all occurrences of "paste" with the root of your palm-paste installation
|
|
|
|
location /paste {
|
2017-03-12 14:51:40 +00:00
|
|
|
if ( $uri !~ ^/paste/(index\.php|css|js|robots\.txt|favicon\.ico|$) ) {
|
|
|
|
rewrite ^/paste/u/(.*)$ /paste/index.php?user=$1? last;
|
|
|
|
rewrite ^/paste/delete/(.*)$ /paste/delete.php?id=$1? last;
|
2017-04-02 12:49:39 +01:00
|
|
|
rewrite ^/paste/([^/]+)/(.*)$ /paste/index.php?page=$1&id=$2? last;
|
2017-03-12 14:51:40 +00:00
|
|
|
rewrite ^/paste/(.*)$ /paste/index.php?page=$1? last;
|
|
|
|
}
|
|
|
|
if ( $uri ~* ^/paste/u/(css|js) ) {
|
|
|
|
rewrite ^/paste/u/(.*)$ /paste/u/$1? last;
|
|
|
|
}
|
|
|
|
if ( $uri ~* ^/paste/delete/(css|js) ) {
|
|
|
|
rewrite ^/paste/delete/(.*)$ /paste/delete/$1? last;
|
|
|
|
}
|
2017-04-02 12:49:39 +01:00
|
|
|
}
|