I want to change my link from usercp.php?do=our_pics&p=$i
to usercp/our_pics/1
.
I have this .htaccess code
RewriteEngine On
RewriteRule usercp/(.*)/(.*) usercp.php?do=$1&p=$2
The problem is when I using the pagination to change the page to another, it doing redirect to main page or page 1, and that because there are problem in mod_rewrite code .
"Edit 1"
After enable RewriteLog and RewriteLogLevel 2, the following is the content of rewrite.log file When the problem occurs.
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#ec2180/initial] (2) [perdir C:/Program Files/wamp/www/ebdaa_v3/] rewrite 'usercp/our_pics/3' -> 'usercp.php?do=our_pics/3'
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#ec2180/initial] (2) [perdir C:/Program Files/wamp/www/ebdaa_v3/] strip document_root prefix: C:/Program Files/wamp/www/ebdaa_v3/usercp.php -> /ebdaa_v3/usercp.php
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#ec2180/initial] (1) [perdir C:/Program Files/wamp/www/ebdaa_v3/] internal redirect with /ebdaa_v3/usercp.php [INTERNAL REDIRECT]
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#724160/initial/redir#1] (1) [perdir C:/Program Files/wamp/www/ebdaa_v3/] pass through C:/Program Files/wamp/www/ebdaa_v3/usercp.php
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#ec6190/initial] (2) [perdir C:/Program Files/wamp/www/ebdaa_v3/] rewrite 'usercp/mainpage' -> 'usercp.php?do=mainpage'
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#ec6190/initial] (2) [perdir C:/Program Files/wamp/www/ebdaa_v3/] strip document_root prefix: C:/Program Files/wamp/www/ebdaa_v3/usercp.php -> /ebdaa_v3/usercp.php
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#ec6190/initial] (1) [perdir C:/Program Files/wamp/www/ebdaa_v3/] internal redirect with /ebdaa_v3/usercp.php [INTERNAL REDIRECT]
127.0.0.1 - - [06/Jan/2013:20:37:26 +0200] [localhost/sid#6828d0][rid#727158/initial/redir#1] (1) [perdir C:/Program Files/wamp/www/ebdaa_v3/] pass through C:/Program Files/wamp/www/ebdaa_v3/usercp.php