Post by Frens » Wed Jul 26, 2017 5:41 pm

Hi.
I made a test.ocmod.xml file

Code: Select all

<modification>
    <name>Tabs</name>
    <code>Tabs-site</code>
    <version>1.0</version>
    <author>test</author>
    <link>http://test.com</link>
    <file path="catalog/view/theme/*/template/information/information.tpl">
        <operation>
            <search><![CDATA[
            $data[<div class="container">
            ]]></search>
            <add position="replace"><![CDATA[
            $data[xxxx
            ]]></add>
        </operation>
    </file>  
</modification>
Whit the extension installer upoads fine and refresh cash in modefications, so everthing looks good., but in the front store nothing happens.

OC v2.3.0.2

Active Member

Posts

Joined
Sat Apr 20, 2013 10:48 pm

Post by IP_CAM » Wed Jul 26, 2017 11:15 pm

<search><![CDATA[$data[<div class="container">]]></search>
<add position="replace"><![CDATA[$data[xxxx]]></add>
---
well, better check again, how OcMod should be written, to make it work! ::)
Ernie

I'm rarely active at the OC Forum lately. To reach me, contact: jti@jacob.ch
A Demoversion of my free OpenCart LIGHT v.1.5.6.5 Software Edition
can be seen in real Action here: http://www.jti.li/shop/
---
1'200+ FREE OC Extension-Repositories - from OC v.1.5.x up,
on the world's largest OC-related Github Site: https://github.com/IP-CAM
---
Image


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by Frens » Wed Jul 26, 2017 11:35 pm

Thanks,

I have look 100 times to a working sample , but can find :choke:
https://github.com/opencart/opencart/wi ... ion-System

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<modification>
    <name>Modification Default</name>
    <version>1.0</version>
    <author>OpenCart Ltd</author>
    <link>http://www.opencart.com</link>
    <file path="catalog/controller/common/home.php">
        <operation>
            <search><![CDATA[
            $data['column_left'] = $this->load->controller('common/column_left');
            ]]></search>
            <add position="replace"><![CDATA[
            test123
            ]]></add>
        </operation>
    </file>  

Active Member

Posts

Joined
Sat Apr 20, 2013 10:48 pm

Post by IP_CAM » Wed Jul 26, 2017 11:55 pm

well, you screwed up by the opening/closing brackets [ .... ]
and such crab could never function anyway: $data[<div class="container">
---
<operation>
<search><![CDATA[
$data['column_left'] = $this->load->controller('common/column_left');
]]></search>
<add position="replace"><![CDATA[
test123
]]></add>
</operation>
Ernie

I'm rarely active at the OC Forum lately. To reach me, contact: jti@jacob.ch
A Demoversion of my free OpenCart LIGHT v.1.5.6.5 Software Edition
can be seen in real Action here: http://www.jti.li/shop/
---
1'200+ FREE OC Extension-Repositories - from OC v.1.5.x up,
on the world's largest OC-related Github Site: https://github.com/IP-CAM
---
Image


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by Frens » Thu Jul 27, 2017 12:10 am

Thanks for help ! works fine now.

Active Member

Posts

Joined
Sat Apr 20, 2013 10:48 pm
Who is online

Users browsing this forum: No registered users and 7 guests