Please Help me with SEO friendly url

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 10-26-2008, 07:26 PM
New Pligger
Pligg Version: beta 9
 
Join Date: Oct 2008
Posts: 12
Hello all,

I need urgent Help.

My site is running fine but after renaming .htaccess I got Internal Server Error after renaming the .htaccess.

My server do not support this line: Options +Indexes +FollowSymlinks -MultiView, So, i removed that line and it worked fine again, I set up the method 1 and I still see the normal URL story.php?title=bla... .... why?

I tested the method 2 and it works but only the categories are fine, the other links give a 404 error.

What to do?... Please help I'm desperate.

If my server do not support this:
Options +Indexes +FollowSymlinks -MultiViewsare is there still posibility to get it working ?

Thanks in advance!

ps: I post here my .htaccess file if this can help:

Quote:
##### Gzip Begin #####
## To enable Gzip and decrease the load times of your Pligg site
## change /home/path/to to your absolute server path and remove the two # from both lines
## php_value auto_prepend_file /home/path/to/begin_gzip.php
## php_value auto_append_file /home/path/to/end_gzip.php

## AddType "text/javascript" .gz
## AddEncoding gzip .gz
## RewriteCond %{HTTP:Accept-encoding} gzip
## RewriteCond %{THE_REQUEST} ^(.*).js
## RewriteCond %{SCRIPT_FILENAME}.gz -f
## RewriteRule ^(.*)\.js $1.js.gz [L]
##### Gzip End #####

##### 404 Error Begin #####
## If Pligg is installed in a subfolder, change the below line to ErrorDocument 404 /name-of-subfolder/404error.php
ErrorDocument 404 /live/404error.php
##### 404 Error End #####

##### Re-directing Begin #####
RewriteEngine on
## If Pligg is installed in a subfolder, change the below line to RewriteBase /name-of-subfolder
RewriteBase /live
## If installed in a subfolder you may need to add ## to the beginning of the next line-----------------------------------
##RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /.*index\.php\ HTTP/

## Remove these two lines if you have a sub-domain like http://ashdigg.pligg.com or http://localhost
## Keep if your site it like http://www.pligg.com
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^\/?(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
##### Re-directing End #####

##### You can find the below lines pre-made for you in the category management section of the admin panel ######
RewriteRule ^(all|pligg)/([^/]+)/?$ story.php?title=$2 [L]
RewriteRule ^(all|pligg)/?$ ?category=$1 [L]
#####

##### URL Method 2 ("Clean" URLs) Begin #####
RewriteRule ^story/([0-9]+)/?$ story.php?id=$1 [L]
RewriteRule ^story/title/([^/]+)/?$ story.php?title=$1 [L]
RewriteRule ^story/([0-9]+)/editcomment/([0-9]+)/?$ edit.php?id=$1&commentid=$2
RewriteRule ^story/([0-9]+)/edit/?$ editlink.php?id=$1
RewriteRule ^story/([0-9]+)/modify/([a-z]+)/?$ linkadmin.php?id=$1&action=$2
RewriteRule ^recommend/([a-zA-Z0-9-]+)/?$ recommend.php?id=$1 [L]
RewriteRule ^category/([^/]+)/?$ index.php?category=$1 [L]
RewriteRule ^upcoming/category/([^/]+)/?$ upcoming.php?category=$1 [L]
RewriteRule ^upcoming/([a-zA-Z0-9]+)/?$ upcoming.php?part=upcoming&order=$1
RewriteRule ^inbox/?$ user.php?view=inbox
RewriteRule ^user/?$ user.php
RewriteRule ^user/view/([a-zA-Z0-9-]+)/?$ user.php?view=$1
RewriteRule ^user/view/([a-zA-Z0-9+]+)/([a-zA-Z0-9+]+)/?$ user.php?view=$1&login=$2
RewriteRule ^user/view/([a-zA-Z0-9+]+)/login/([a-zA-Z0-9+]+)/?$ user.php?view=$1&login=$2
RewriteRule ^user/([a-zA-Z-]+)/link/([0-9+]+)/?$ user_add_remove_links.php?action=$1&link=$2
RewriteRule ^published/?$ index.php
RewriteRule ^published/([a-zA-Z0-9-]+)/?$ index.php?part=$1
RewriteRule ^published/([a-zA-Z0-9-]+)/category/([a-zA-Z0-9_-]+)/?$ index.php?part=$1&category=$2
RewriteRule ^upcoming/([a-zA-Z0-9-]+)/category/([a-zA-Z0-9_-]+)/?$ upcoming.php?part=upcoming&order=$1&category=$2
RewriteRule ^search/(.+)/?$ search.php?search=$1
RewriteRule ^searchurl/(.+)/?$ search.php?url=$1
RewriteRule ^login/?$ login.php
RewriteRule ^login/([a-zA-Z0-9-]+)/?$ login.php?return=$1
RewriteRule ^login/([a-zA-Z0-9-]+)/([a-zA-Z0-9-]+)/?$ login.php?return=$1/$2
RewriteRule ^register/?$ register.php
RewriteRule ^topusers/?$ topusers.php
RewriteRule ^about/([a-zA-Z0-9-]+)/?$ faq-$1.php
RewriteRule ^upcoming/?$ upcoming.php
RewriteRule ^submit/?$ submit.php
RewriteRule ^rss/?$ rss.php
RewriteRule ^rss/([a-zA-Z0-9-]+)/?$ rss.php?status=$1
RewriteRule ^rss/category/([a-zA-Z0-9_-]+)/?$ rss.php?category=$1
RewriteRule ^rss/search/([a-zA-Z0-9-]+)/?$ rss.php?search=$1
RewriteRule ^rss/user/([a-zA-Z0-9-]+)/?$ rss.php?user=$1
RewriteRule ^rss/user/([a-zA-Z0-9-]+)/([a-zA-Z0-9-]+)/?$ userrss.php?user=$1&status=$2
RewriteRule ^trackback/([0-9]+)/?$ trackback.php?id=$1
RewriteRule ^profile/?$ profile.php
RewriteRule ^admin/?$ admin_index.php
RewriteRule ^tagcloud/?$ cloud.php
RewriteRule ^tagcloud/range/([0-9]+)/?$ cloud.php?range=$1 [L]
RewriteRule ^tag/(.+)/(.+)/?$ search.php?search=$1&tag=true&from=$2 [QSA,NC,L]
RewriteRule ^tag/(.+)/?$ search.php?search=$1&tag=true [QSA,NC,L]
RewriteRule ^live/?$ live.php
RewriteRule ^out/([^/]+)/?$ out.php?title=$1 [L]
RewriteRule ^settemplate/?$ settemplate.php
RewriteRule ^comments/?$ live_comments.php
RewriteRule ^live_published/?$ live_published.php
RewriteRule ^unpublished/?$ live_unpublished.php
RewriteRule ^logout/([a-zA-Z0-9-]+)/([a-zA-Z0-9-]+)/?$ login.php?op=logout&return=$1/$2
RewriteRule ^published/page/([^/]+)/?$ index.php?page=$1 [L]
RewriteRule ^published/page/([^/]+)/category/([^/]+)/?$ index.php?page=$1&category=$2 [L]
RewriteRule ^published/page/([^/]+)/([^/]+)category/([^/]+)/?$ index.php?page=$1&part=$2&category=$3 [L]
RewriteRule ^upcoming/page/([0-9]+)/?$ upcoming.php?page=$1 [L]
RewriteRule ^upcoming/page/([^/]+)/category/([^/]+)/?$ upcoming.php?page=$1&category=$2 [L]
RewriteRule ^upcoming/page/([^/]+)/upcoming/([^/]+)/?$ upcoming.php?page=$1&part=upcoming&order=$2 [L]
RewriteRule ^upcoming/page/([^/]+)/upcoming=([^/]+)category/([^/]+)/?$ upcoming.php?page=$1&part=upcoming&order=$2&catego ry=$3 [L]
RewriteRule ^topusers/page/([^/]+)/?$ topusers.php?page=$1 [L]
RewriteRule ^topusers/page/([^/]+)/sortby/([^/]+)?$ topusers.php?page=$1&sortby=$2 [L]
RewriteRule ^admin_links/page/([^/]+)/?$ admin_links.php?page=$1
RewriteRule ^admin_comments/page/([^/]+)/?$ admin_comments.php?page=$1
RewriteRule ^admin_users/page/([^/]+)/?$ admin_users.php?page=$1
RewriteRule ^comments/page/([^/]+)/?$ live_comments.php?page=$1 [L]
RewriteRule ^published/page/([^/]+)/?$ live_published.php?page=$1 [L]
RewriteRule ^unpublished/page/([^/]+)/?$ live_unpublished.php?page=$1 [L]
RewriteRule ^published/page/([^/]+)/([^/]+)/?$ index.php?page=$1&part=$2 [L]
RewriteRule ^published/page/([^/]+)/range/([^/]+)/?$ ?page=$1&range=$2 [L]
RewriteRule ^search/page/([^/]+)/search/([^/]+)/?$ search.php?page=$1&search=$2 [QSA,NC,L]
RewriteRule ^user/page/([^/]+)/([^/]+)/([^/]+)/?$ user.php?page=$1&view=$2&login=$3 [L]
RewriteRule ^statistics/page/([^/]+)/?$ module.php?module=pagestatistics&page=$1
RewriteRule ^view/([^/]+)/?$ admin_users.php?mode=view&user=$1
##### URL Method 2 ("Clean" URLs) End #####
Reply With Quote
  #2 (permalink)  
Old 10-26-2008, 08:36 PM
chuckroast's Avatar
Pligg Developer/Coder/Designer
Pligg Version: SVN
Pligg Template: Social Pro Kit
 
Join Date: Jun 2006
Posts: 5,448
Please save everyone time by searching the forums first before starting a new thread. If you had, you would have seen this has been asked numerous times before.

In the category section of the admin panel it clearly states that "If using url method 2 you will need to copy the following "generated code" to your .htaccess file"
Reply With Quote
  #3 (permalink)  
Old 10-27-2008, 07:38 AM
New Pligger
Pligg Version: beta 9
 
Join Date: Oct 2008
Posts: 12
Hello,

Thanks a lot for your quick help, I apologize if this thread is similar to others, I really made a search and did not find it.

Now the SEO urls are working fine (thank you), BUT some URLs are returning 404 page not found error.

they are:

upcoming news
profile
submit new story
top users
live
out.php ( the outgoing link to the external source)

Do you have any idea about the cause. Please!

Thanks in advance,
Fernando.

Last edited by fernan; 10-27-2008 at 07:51 AM.
Reply With Quote
  #4 (permalink)  
Old 10-29-2008, 09:47 AM
New Pligger
Pligg Version: beta 9
 
Join Date: Oct 2008
Posts: 12
Please, any advise on my last post ?... This answer is not in the forum ...

I appreciate any help.
Reply With Quote
  #5 (permalink)  
Old 10-29-2008, 11:13 AM
chuckroast's Avatar
Pligg Developer/Coder/Designer
Pligg Version: SVN
Pligg Template: Social Pro Kit
 
Join Date: Jun 2006
Posts: 5,448
I would suggest adding back the
Options +Indexes +FollowSymlinks -MultiView
but this time take away the-MultiView so it's just
Options +Indexes +FollowSymlinks
Reply With Quote
  #6 (permalink)  
Old 10-30-2008, 01:46 PM
New Pligger
Pligg Version: beta 9
 
Join Date: Oct 2008
Posts: 12
Thank you so much for replying again!

Unfortunately I get Internal Server Error if I back: Options +Indexes +FollowSymlinks ( I tried all combinations)

Do I have other alternative ?

What about removing the some lines like:

"RewriteRule ^upcoming/?$ upcoming.php" to have the normal link on (upcoming, live, out and rss) ... I tried romoving the lines but still make the link seo friendly with 404 error.



I'm willing to pay for support please let me know is someone is interested.

Thanks all!

by the way I will become pligg donator just created a paypal account. I'm in love with pligg.

Regards
fernando.
Reply With Quote
  #7 (permalink)  
Old 10-30-2008, 07:05 PM
cmstheme's Avatar
Donor/Coder
Pligg Version: 9.9
Pligg Template: Squaretle
 
Join Date: Jan 2007
Location: Philippines
Posts: 531
Sad to say but enabling seo-friendly URLs brings a lot of problems for SEO purposes. You can have too many duplicate content if you enable that option.

I think it's better to leave it as default something like /story.php?id=xxx

Dynamic URLs is not a problem anymore, esp. with Google. Here's an article that Google can crawl dynamic URLs and even recommend not to rewrite dynamic URLs to static: Official Google Webmaster Central Blog: Dynamic URLs vs. static URLs
Reply With Quote
  #8 (permalink)  
Old 10-30-2008, 11:41 PM
Pligg Donor
 
Join Date: Jul 2007
Posts: 286
Quote:
Originally Posted by cmstheme View Post
Sad to say but enabling seo-friendly URLs brings a lot of problems for SEO purposes. You can have too many duplicate content if you enable that option.

I think it's better to leave it as default something like /story.php?id=xxx

Dynamic URLs is not a problem anymore, esp. with Google. Here's an article that Google can crawl dynamic URLs and even recommend not to rewrite dynamic URLs to static: Official Google Webmaster Central Blog: Dynamic URLs vs. static URLs
Thanks cmstheme for sharing this useful article. BTW, I gave up using 'SEO friendly URL method' as I came across with lot of problems. I am happy with the default method. There are lot of things & factors to get better rank in search engines.
Reply With Quote
  #9 (permalink)  
Old 10-30-2008, 11:58 PM
cmstheme's Avatar
Donor/Coder
Pligg Version: 9.9
Pligg Template: Squaretle
 
Join Date: Jan 2007
Location: Philippines
Posts: 531
Yeah, the default dynamic URLs are much better than the seo-friendly URLs. When I enable it on my Pligg site, I can see a lot of duplicate contents using the Google Webmaster Central.
Reply With Quote
Reply

Tags
htaccess, options, seo, url

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Friendly URL's for categories works, but for stories not sixlaneve Questions and Comments 7 05-08-2011 11:39 PM
Friendly URL's for stories And (error - Oops, what you're looking for isn't here!) roor Questions and Comments 6 07-12-2009 01:54 PM
Seo Friendly Urls - Urlmethod 2 canadianguy33 Questions and Comments 15 05-12-2007 10:57 PM
Search and friendly urls problem pligiro Questions and Comments 1 02-27-2007 12:43 PM
$16 to Anyone That Can Solve My Friendly Url Problem canadianguy33 Questions and Comments 2 07-21-2006 04:49 PM


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