I need help to get this done.
My webpages have formatted urls in this pattern: “http://qifu.us/index.php?page=item&id=4” for example – if there are more pages, only the last page id number will be different.
I want to get this part “index.php?page=item&id=” out, and shortened like “http://qifu.us/s4“, when a user input the shortened url into to address bar, it will be directed to the right page, which is the true url.
Actually an htaccess will be very good for this purpose.
For urls like
http://qifu.us/s4 do the following: Create a file with name
.htaccess and place at your root directory with the following content.
RewriteEngine On RewriteRule ^s([^/]*)$ /index.php?page=item&id=$1 [L]