Have version 1.5.6.1 Vqmod 2.1
I have a wordpress blog and I want to add a 'blog' link on my main header menu in my opencart site
I was told I could use this
<?xml version="1.0" encoding="UTF-8"?>
-<modification>
<id>Add BLOG entry to top menu</id>
<version>1.0</version>
<vqmver>1.x</vqmver>
<author>www.ihomedeal.com</author>
-<file name="catalog/controller/common/header.php">
-<operation info="Add information pages directly to the category menu">
-<search position="before">
<![CDATA[ $this->children = array( ]]>
</search>
-<add>
<![CDATA[ $this->data['categories'][] = array( 'name' => 'Blog', 'children' => '', 'column' => 1, 'href' => $this->url->link('https://{site name}.com/blog/', '') ); ]]>
</add>
</operation>
</file>
</modification>
However all this does is try to take the user to a page within the site called blog, so they get 'the this page does not exist' rather than connecting to the actual blog page.
Can anyone offer any suggestions, advice or links to where I can get an extension that will work
and writing code is not a something I'm into...
Thanks
I have a wordpress blog and I want to add a 'blog' link on my main header menu in my opencart site
I was told I could use this
<?xml version="1.0" encoding="UTF-8"?>
-<modification>
<id>Add BLOG entry to top menu</id>
<version>1.0</version>
<vqmver>1.x</vqmver>
<author>www.ihomedeal.com</author>
-<file name="catalog/controller/common/header.php">
-<operation info="Add information pages directly to the category menu">
-<search position="before">
<![CDATA[ $this->children = array( ]]>
</search>
-<add>
<![CDATA[ $this->data['categories'][] = array( 'name' => 'Blog', 'children' => '', 'column' => 1, 'href' => $this->url->link('https://{site name}.com/blog/', '') ); ]]>
</add>
</operation>
</file>
</modification>
However all this does is try to take the user to a page within the site called blog, so they get 'the this page does not exist' rather than connecting to the actual blog page.
Can anyone offer any suggestions, advice or links to where I can get an extension that will work
and writing code is not a something I'm into...
Thanks
My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Hi Yes I have looked at those and tried several. Seems they either are not for external links, not for my version, or put them on the wrong menu. The example I gave put it on the correct menu.. but is for an internal link only so doesn't work.
Thanks
Thanks
My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Change $this->url->link('https://{site name}.com/blog/', '') );
to 'https://{site name}.com/blog/'
to 'https://{site name}.com/blog/'
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
Sorry about that.
Here's the full correct code:
Here's the full correct code:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<modification>
<id>Add BLOG entry to top menu</id>
<version>1.0</version>
<vqmver>1.x</vqmver>
<author>www.ihomedeal.com</author>
-<file name="catalog/controller/common/header.php">
-<operation info="Add information pages directly to the category menu">
-<search position="before">
<![CDATA[ $this->children = array( ]]>
</search>
-<add>
<![CDATA[ $this->data['categories'][] = array( 'name' => 'Blog', 'children' => '', 'column' => 1, 'href' => 'https://yourdomain.com/blog/'); ]]>
</add>
</operation>
</file>
</modification>
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
Who is online
Users browsing this forum: Bing [Bot] and 22 guests