-2

Currently i'm working on this. I would like to change my url from

http://www.demo.com/userhome.php?view=prsnl_pge&pge_id=12 

to

http://www.demo.com/(value of page id)
Abhishek Gurjar
  • 7,426
  • 10
  • 37
  • 45
Syam sg
  • 11
  • 4
  • I answered several of similar questions, please see http://stackoverflow.com/a/37701761/1741542, http://stackoverflow.com/a/15214206/1741542 – Olaf Dietsche Sep 19 '16 at 08:11

1 Answers1

0

Specifically for your condition please try it like this in root .htaccess,

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([\w-]+)$ userhome.php?view=prsnl_pge&pge_id=$1 [L]
Abhishek Gurjar
  • 7,426
  • 10
  • 37
  • 45