Changing the storycattitle in URL method 2 -with name and id

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 01-06-2010, 12:30 PM
New Pligger
Pligg Version: 1.0.3
 
Join Date: Nov 2009
Location: Germany
Posts: 5
Hi,
i want to add the Story ID to the URL with the Title and category.

in lib/html1.php

i changed the line 552 to

return getmyurl("storycattitle", $var1, $var2, $var3);

and the line 694:
from
If ($x == "storycattitle") {return my_pligg_base."/" . $var1 . "/" . $var2 ."/";}
to
If ($x == "storycattitle") {return my_pligg_base."/" . $var1 . "/id-" . $var3 ."/" . $var2 ."/";}

The Urls are displayed correctly... but when i click to them i become a 404 error...

I know that there is more to change (in the htaccess and ?). But i ask for help because i haven't experience in mod_rewrite.

Now the Urls are
http:// DOMAIN / CATEGORYNAME / STORYNAME

and they should look

http:// DOMAIN / CATEGORYNAME / id-STORYID / STORYNAME

I hope you understand me

Any help are welcome. Thanks.

Greetings from Germany
Reply With Quote
  #2 (permalink)  
Old 01-11-2010, 01:18 PM
New Pligger
Pligg Version: 1.0.3
 
Join Date: Nov 2009
Location: Germany
Posts: 5
It's working...

I changed

RewriteRule ^([^/]+)/([^/]+)/?$ story.php?title=$2 [L]

to

RewriteRule ^([^/]+)/(.*)/([^/]+)/?$ story.php?title=$3 [L]
Reply With Quote
  #3 (permalink)  
Old 04-04-2010, 02:00 PM
New Pligger
 
Join Date: Nov 2009
Posts: 16
i m using pligg version 1.03..
My htaccess file contain only this code
## Rename this file to .htaccess if you don't

## want people viewing your tpl files



<files ~ "\.tpl$">

order deny,allow

allow from none

deny from all

</files>

-- i m using wisitie template...
when i enable method 2 for seo link and put the code which is mentioned below category manger in htaccess file.. my whole layout destroy and link does not work.. all the links show page not found..
plz give me the solution
Thanks
Reply With Quote
Reply

Tags
seo, storycattitle

Thread Tools
Display Modes




Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development