Code

url rewriting: take longest and first match