match URL into $ with ^(.*)/topic-(.+)\.html\?*(.*)$ if matched then set URL = $1/portal.php?mod=topic&topic=$2&$3 endif match URL into $ with ^(.*)/article-([0-9]+)-([0-9]+)\.html\?*(.*)$ if matched then set URL = $1/portal.php?mod=view&aid=$2&page=$3&$4 endif match URL into $ with ^(.*)/forum-(\w+)-([0-9]+)\.html\?*(.*)$ if matched then set URL = $1/forum.php?mod=forumdisplay&fid=$2&page=$3&$4 endif match URL into $ with ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$ if matched then set URL = $1/forum.php?mod=viewthread&tid=$2&extra=page\%3D$4&page=$3&$5 endif match URL into $ with ^(.*)/group-([0-9]+)-([0-9]+)\.html\?*(.*)$ if matched then set URL = $1/forum.php?mod=group&fid=$2&page=$3&$4 endif match URL into $ with ^(.*)/space-(username|uid)-(.+)\.html\?*(.*)$ if matched then set URL = $1/home.php?mod=space&$2=$3&$4 endif match URL into $ with ^(.*)/blog-([0-9]+)-([0-9]+)\.html\?*(.*)$ if matched then set URL = $1/home.php?mod=space&uid=$2&do=blog&id=$3&$4 endif match URL into $ with ^(.*)/(fid|tid)-([0-9]+)\.html\?*(.*)$ if matched then set URL = $1/index.php?action=$2&value=$3&$4 endif