vqmod_opencart.xml (1827B)
1 <?xml version="1.0" encoding="UTF-8"?> 2 <modification> 3 <id>VQMOD CORE FOR OPENCART - DO NOT REMOVE</id> 4 <version>1.4.x and above</version> 5 <vqmver required="true">2.6.0</vqmver> 6 <author>vqmod.com</author> 7 8 <file name="system/startup.php,system/engine/*.php,system/library/*.php,admin/controller/extension/*.php,system/library/template/*.php,catalog/controller/event/theme.php,system/library/template/Twig/*.php" error="skip"> 9 <operation error="skip" info="For non OCMod includes/requires"> 10 <search position="replace" regex="true"><![CDATA[~^(\s*)(require|include)(_once)?(\s+|\()(?!VQMod::modCheck\()(?!modification\()([^);]+)~]]></search> 11 <add><![CDATA[$1$2$3$4\\VQMod::modCheck($5)]]></add> 12 </operation> 13 <operation error="skip" info="For OCMod includes/requires - OPERATION MUST BE AFTER NON OCMOD INCLUDES/REQUIRES OPERATION"> 14 <search position="replace" regex="true"><![CDATA[~(require|include)(_once)?\((?!VQMod::modCheck\()modification\(([^)]+)~]]></search> 15 <add><![CDATA[$1$2(\\VQMod::modCheck(modification($3), $3]]></add> 16 </operation> 17 </file> 18 19 <file name="system/library/template/Twig/*.php" error="skip"> 20 <operation error="skip" info="Add Twig support"> 21 <search position="replace"><![CDATA[dirname(__FILE__).'/../']]></search> 22 <add><![CDATA[DIR_SYSTEM . 'library/template/']]></add> 23 </operation> 24 </file> 25 26 <file name="system/library/template/Twig/Loader/*.php" error="skip"> 27 <operation error="skip" info="Add Twig support"> 28 <search position="replace"><![CDATA[= $realpath;]]></search> 29 <add><![CDATA[= VQMod::modCheck($realpath, DIR_TEMPLATE . $name);]]></add> 30 </operation> 31 </file> 32 33 </modification>