Jump to content

URL REWRITE AND COMMENTS SCRIPT !!


stone.fletcher

Recommended Posts

i got a small issue with a comment script nothing to do with the comments script itself but i got this page who use a url rewrite  when i got a lot s of comments on the page  the pagination is sending me to the second comments page but the problem is the url redirect with .HTACCESS !! it give me the original page. exemple::

my redirected url is  : http://localhost/newssite/15/breakingnews.html

when i click on the comments page 2  i got this : http://localhost/newssite.php?comm_page=2

how can i fix that ???? so when i click on the the comm_page 2 i get back to :

http://localhost/newssite/15/breakingnews.html

thanks for your help .

 

Link to comment
https://forums.phpfreaks.com/topic/222252-url-rewrite-and-comments-script/
Share on other sites

Sorry for the all caps !!  ok but it is a news website everything can work if it is a static link but the problem is i  will be forced to make a lot of pages  for each articles and i dont want to do that so i used url rewriting so i can use one page and each articles got an id .

I found the solution i changed the rewriterule !! before it was like this::

 

     

RewriteRule ^cal/([0-9]+)/([a-z]*)$ call.php?id=$1

 

RewriteRule  ^newslog/([0-9]+)/([a-z]*).php$  /newslog.php?id=$1&rubrique=$2 [L]

 

even my css my js and my img wasnt working properly so i rewrite the rule

 

 

     

RewriteRule ^call-([0-9]+)-([a-z]*)$ call.php?id=$1

 

RewriteRule  ^newssite-([0-9]+)-([a-z]*).php$  /newssite.php?id=$1&rubrique=$2 [L]

 

and now it 's working !!

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.