Hi,

I have a link that works by using a unique identifier product code. However I am trying to put the product name into the link but I am so far stuck with this.

Does anyone have any suggestions please?

Code:
This works..

/products/product/6550

This doesn't work..

/products/product/6550/clearance---hatherley-high-gloss-2-drawer-bedside-chest-in-walnut-and-red
htaccess file..

Code:
Options -Indexes
Options -MultiViews
Options +FollowSymLinks

# Prevent viewing of htaccess file
<Files ~ "^\.ht">
order allow,deny
deny from all
satisfy all
</Files>

# Error Pages
ErrorDocument 404 /404-error.php

# Rewrite Rules
<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^([a-z]+)/([a-z\-]+)$ /$1/$2.php [QSA,L]
  RewriteRule ^products/product/([0-9]+)/(.*)$ products/product.php?product_id=$1 [QSA,L]
</IfModule>

Code:
<div class="productimageborder"><a href="/products/product/<?php echo $row['product_id'] . '/' . $row['linkname']; ?>" ><img src="<?php echo $row['image_link']; ?>" alt="<?php echo $row['name']; ?>" /></a></div>