help me with that one... I'm really a new comer to this subject. I've placed this during my .htaccess file.

RewriteEngine On

RewriteRule ^gallery/([-9]+)/?$ viewgallery.php?cid=1 [NC,L]

To create the hyperlink

http://www.123456.com/viewgallery.php?cid=1

seem like this...

http://www.123456.com/viewgallery/1/

Things I am doing wrong... ? It's not working...

Any assistance is appreciated! Thanks greatly....

You are spinning "gallery/1/" rather than viewgallery.

RewriteRule ^viewgallery/([0-9]+)/?$ viewgallery.php?cid=$1 [NC,L]