Google has updated my site's homepage URL in their index as...
example,com/index.php?route=common/home <--VERY BAD
What is the fix for this? Has anyone created code for a canonical tag for the home page? I searched, but couldn't find anything.
example,com/index.php?route=common/home <--VERY BAD
What is the fix for this? Has anyone created code for a canonical tag for the home page? I searched, but couldn't find anything.
My store is awesomely powered by OpenCart 1.5.5.1.
edit: catalog/controller/common/home.php
after
add
after
Code: Select all
$this->document->setDescription($this->config->get('config_meta_description'));
Code: Select all
$this->document->addLink('http://www.yourdomain.com', 'canonical');
Hi uksitebuilder,uksitebuilder wrote:edit: catalog/controller/common/home.php
afteraddCode: Select all
$this->document->setDescription($this->config->get('config_meta_description'));
Code: Select all
$this->document->addLink('http://www.yourdomain.com', 'canonical');
Would it be possible to get the above code working on a multi-store setup?
Thanks
G47F - That can be done quite simply by changing
to
Code: Select all
$this->document->addLink('http://www.yourdomain.com', 'canonical');
Code: Select all
$this->document->addLink($this->config->get('config_url'), 'canonical');
Works perfectly, thanks JayJAY6390 wrote:G47F - That can be done quite simply by changingtoCode: Select all
$this->document->addLink('http://www.yourdomain.com', 'canonical');
Code: Select all
$this->document->addLink($this->config->get('config_url'), 'canonical');
This really is the soultion I'm looking for, but on OC 1.5.1.3 altering this php file didn't work. Could it be that my OC install is in a WordPress subfolder? I wouldn't have thought so, but I'm not sure.
Any help would be appreciated. Thanks.
John
Any help would be appreciated. Thanks.
John
Who is online
Users browsing this forum: No registered users and 16 guests