We updated the whmcs version to the newest one.
Added only those changes (following examples from your website)
hooks.php in registrars/modules/ourmodule/
<?php
add_hook( 'DomainValidation', 1, function( $vars)
{
//some extra logging in here to be sure the hook was called
$extraTemplateVariables = array();
// set a fixed value
$extraTemplateVariables['fixedValue'] = 'abc';
// return array of template variables to define
return $extraTemplateVariables;
};
?>
//////////////////////////////
and added the first row to domainchecker.tpl
<p>The fixed value is for domainchecker tpl: {$fixedValue}.</p>
and to domainchecker-results.tpl
<p>The fixed value is for domainchecker-results tpl: {$fixedValue}.</p>
/////////////////////////
Setup -> General -> Security -> Allow Smarty PHP Tags is ON
Result:
We can see the hook was called each time when refreshing / and calling by ajax.
But at the moment $fixedValue is empty either when refreshing the site and when checking is done by ajax
Any suggestions are welcome.
JG
We would appreciate any suggestions.