Help with Php coding for seo

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
keithbyrne
Forum Newbie
Posts: 18
Joined: Thu Sep 20, 2007 5:20 am

Help with Php coding for seo

Post by keithbyrne »

Hey Guys ! Can any of you fantastic people in here help me ???

None of my product pages are working its sending me to this webpage http://oscommerce.local/catalog/blabla- ... -1_53.html instead of this http://oscommerce.local/catalog/product ... ucts_id=28 which is good but its not showing the page all im getting is this :

Object not found!

The requested URL was not found on this server.

Error 404

So im guessing it has something to do with .htaccess but i think its set up ok in .htaccess

Options +FollowSymLinks
RewriteEngine On
RewriteBase /catalog/

Has anyone got any ideas ive had the problem for nearly two weeks now i was try a SEO update

Please help if you can !
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

Add

Code: Select all

RewriteRule ^(.*?)\.html$ product_info_lightbox.php?products_name=$1
Of course, you cannot obtain the id the product from the url, so you'll need to obtain it using a query based on the product_name
keithbyrne
Forum Newbie
Posts: 18
Joined: Thu Sep 20, 2007 5:20 am

Post by keithbyrne »

Hey i actually have this in my .htaccess file

Options +FollowSymLinks
RewriteEngine On
RewriteBase /catalog/

RewriteRule ^(.*)-p-(.*).html$ product_info.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-c-(.*).html$ index.php?cPath=$2&%{QUERY_STRING}
RewriteRule ^(.*)-m-([0-9]+).html$ index.php?manufacturers_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pi-([0-9]+).html$ popup_image.php?pID=$2&%{QUERY_STRING}
RewriteRule ^(.*)-t-([0-9]+).html$ articles.php?tPath=$2&%{QUERY_STRING}
RewriteRule ^(.*)-a-([0-9]+).html$ article_info.php?articles_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pr-([0-9]+).html$ product_reviews.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pri-([0-9]+).html$ product_reviews_info.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-i-([0-9]+).html$ information.php?info_id=$2&%{QUERY_STRING}

Is there something to change in this ??

Cheers
Post Reply