You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It took a lot of googling and asking in the IRC channel to get this. Might be handy to add thing to the cookbook / docs.
Most applications will work if your regular expression is ^(.*)$ and the substitution is /index.php?path=$1
But if you have an application that uses urls like "/settings/panel/ssh/?edit=true" you will end up with a rewrite like: "index.php?path=/settings/panel/ssh/?edit=true" which will break and return a 404 due to the double ?
The solution is to use the regular expression: ([^\?])(?:?(.))?
and as substitution: index.php?path=$1&$2
If $2 is empty you'll have a weird trailing & but this shouldn't break anything.
note: Phabricator is one of the applications that uses query strings in their friendly urls.
The text was updated successfully, but these errors were encountered:
@thul I'll see if I can figure it out myself, but can you put your full list of cherokee rewrite rules for phabricator up on github, similar to how I've done for YOURLS in lylebrown\YOURLS-Cherokee?
It took a lot of googling and asking in the IRC channel to get this. Might be handy to add thing to the cookbook / docs.
Most applications will work if your regular expression is ^(.*)$ and the substitution is /index.php?path=$1
But if you have an application that uses urls like "/settings/panel/ssh/?edit=true" you will end up with a rewrite like: "index.php?path=/settings/panel/ssh/?edit=true" which will break and return a 404 due to the double ?
The solution is to use the regular expression: ([^\?])(?:?(.))?
and as substitution: index.php?path=$1&$2
If $2 is empty you'll have a weird trailing & but this shouldn't break anything.
note: Phabricator is one of the applications that uses query strings in their friendly urls.
The text was updated successfully, but these errors were encountered: