You are here:  » SEO Enhancement Modification

Support Forum



SEO Enhancement Modification

Submitted by sbedigital on Fri, 2012-05-11 19:27 in

Hi Dave,

I just wonder whether it possible to have proper met tag for individual section. I have looked various theards, one way or another they don't fits proper SEO requirement.

Here is one problem; When a category is selected your $q variable will print out category:category_name. This means I need to change code that assings items to $q in the search.php (I assume). Similar problem goes for BRAND, MERCHANT and PRODUCT page itself.

Is there any way I can have titles as follows:

in category
<title>abc company category search for [category]</title>
[category] is the placeholder variable

in brand
<title>abc company brand search for [brand]</title>
[brand] is the placeholder variable

in merchant
<title>abc company merchant search for [merchant]</title>
[brand] is the placeholder variable

in search results
<title>abc company shopping results for [keyword]</title>
[keyword] is the placeholder variable

It is important that actual placeholder variables returns the just item itself e.g shoes not category:shoes also it follows the rewirte rules and page numbering rules.

In terms of page numbering, it would even better if I could make it as follows:

in search results
<title>abc company shopping results page XXX for [keyword]</title>

Similar patter to follow in MERCHANT, BRAND, CATEGORY as well.

Really appreciate your marvelous help and the app itself.

Noor

Submitted by support on Sun, 2012-05-13 09:31

Hello Noor,

Sure - in search.php look for where title is currently set by the following code at line 320:

    $header["title"] = htmlentities($q,ENT_QUOTES,$config_charset);

...and REPLACE with:

switch($parts[0])
{
  case "merchant":
  case "category":
  case "brand":
    $header["title"] = "ABC company ".$parts[0]." search results page ".$page." for ".htmlentities($parts[1],ENT_QUOTES,$config_charset);
    break;
  default
    $header["title"] = "ABC company shopping results page ".$page." for ".htmlentities($parts[1],ENT_QUOTES,$config_charset);
    break;
}

There is already code to append the page to the end of the title so you probably want to comment out or delete line 335:

  $header["title"] .= " | ".translate("Page")." ".$page;

Cheers,
David.
--
PriceTapestry.com