0

I am writing a short script to add to catalog/model/checkout/order.php using vqmod in Opencart. However it seems to add the code twice. Its worth mentioning it also seems to create two files

vq2-catalog_model_checkout_order.php

and

vq2-vqmod_vqcache_vq2-catalog_model_checkout_order.php

Its in this second file that the code is repeating itself.

<modification>
    <id>MyMod</id>
    <version>203.1</version>
    <vqmver>2.5.1</vqmver>
    <author>My Company</author>
    <email>a@example.com</email>
    <website>http://www.example.com/</website>
    <file name="catalog/model/checkout/order.php"  error="skip">
        <operation error="skip">
            <search position="after"><![CDATA[
                $text .= $language->get('text_new_footer') . "\n\n";
                ]]></search>
            <add trim="true"><![CDATA[
                    // add code here
            ]]></add>
        </operation>
    </file>
</modification>

outcome in the second file vq2-vqmod_vqcache_vq2-catalog_model_checkout_order.php:

$text .= $language->get('text_new_footer') . "\n\n";
// add code here
// add code here  
Adrian
  • 1,976
  • 5
  • 41
  • 105

0 Answers0