[Webinar] Streamline your web hosting managementRegister Today

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 210
  • Last Modified:

shortening URLs using mod rewrite

The url of my site is http://www.mysite123.com/?action=services

I would like the url to be like http://www.mysite123.com/services

please help
1 Solution
So a call of /services should be rewritten internally to /?action=services

RewriteEngine on
RewriteRule ^([^/.]+)$ /?action=$1 [L]

note: you must change all links manually to /services etc. - mod_rewrite can't change your html source code and the <a href...> link.

Featured Post

[Webinar] Kill tickets & tabs using PowerShell

Are you tired of cycling through the same browser tabs everyday to close the same repetitive tickets? In this webinar JumpCloud will show how you can leverage RESTful APIs to build your own PowerShell modules to kill tickets & tabs using the PowerShell command Invoke-RestMethod.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now