-- url of the page with the problem -- : localhost
-- HikaShop version -- : 2.5.0
-- Joomla version -- : 3.4.3
-- PHP version -- : 5.5.12
-- Browser(s) name and version -- : Firefox 37.0.2
Hello,
I'm trying to display some javascript code at the end of checkout (on last checkout page - after customer confirms order).
I found in your API docs some very useful info, for now I made some simple plugin. It has one parameter, under Extensions->Plugins->myplugin I can enter this param and everything is saving fine (plugin is group="hikashop" and it's published etc., I checked all things twice). Now in my php file I'm trying simple things like:
defined('_JEXEC') or die('Restricted access');
class plgHikashopMyPlugin extends JPlugin {
function plgHikashopMyPlugin(&$subject, $config){
parent::__construct($subject, $config);
}
function onAfterOrderCreate(&$order, &$send_email) {
$document = JFactory::getDocument();
$document->addScriptDeclaration('SOME_DUMMY_CODE = 1');
}
}
However no matter what, SOME_DUMMY_CODE doesn't appear on my after checkout (confirmation) page.
Could you please suggest why? Maybe it's not possible to "echo" anything through triggers?
I was trying also: onAfterOrderConfirm(&$order,&$methods,$method_id), didn't work.
Best regards,
Chris