VirtueMart Forum

VirtueMart 2 + 3 => General Questions => Topic started by: PRO on September 10, 2011, 15:03:32 pm

Title: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: PRO on September 10, 2011, 15:03:32 pm
There should be an option to display category name OR NOT in the product page title.

OR, for an even better option
Display Category Name YES or NO

IF YES Front or Back
Title: Re: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: PRO on September 15, 2011, 12:53:19 pm
Milbo, is there a chance we can have this added?

Many users will not want the Category Name in the Page title of the product. For SEO
Title: Re: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: Milbo on September 15, 2011, 13:05:57 pm
Oh, we can easily add it, even you can add it easily.

Just add the option to the config. you dont have anything to consider. just copy another checkbox, then write an if ... It takes more time to exactly understand what you mean than to write it, lol.

So how do you mean this "for SEO"?
Title: Re: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: PRO on September 15, 2011, 13:17:57 pm
Currently on the product page the page title is

Category Name : Product Name

It would be best to have 3 options

1) Category Name : Product Name
2) Product Name : Category Name
3) Product Name


Yes, this is for best SEO.

I dont want the category name in my product page title at all.
BUT, some users will want it.

So best to have a choice.

Title: Re: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: Tirrawarra on October 21, 2011, 01:29:11 am
Hello, was there any progress on this?

if its as simple as Milbo suggests what file would we modify?

any help would be appreciated.

cheers Steve
Title: Re: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: PRO on October 21, 2011, 12:35:20 pm
views/productdetails/view.html.php

// Set the titles
      $document->setTitle( strip_tags($category->category_name.' : '.$product->product_name));

You can remove one, or change the order
Title: Re: Request: Category Name (OPTIONAL ) in Product Page Title
Post by: Tirrawarra on November 09, 2011, 00:09:37 am
thanks - BanquetTables.pro

your answer was what I needed!