function price_in_words($amount, $doc_type)
{
}
+
//
// Exchange rate currency $curr as on date $date.
// Keep in mind FA has internally implemented 3 exrate providers
$Hooks = array();
// include current language related $Hooks object if locale file exists
- if (file_exists($path_to_root . "/lang/".$_SESSION['language']->code."/locale.inc"))
+ $lang_code = clean_file_name($_SESSION['language']->code);
+ if (file_exists($path_to_root . "/lang/" . $lang_code . "/locale.inc"))
{
- include_once($path_to_root . "/lang/".$_SESSION['language']->code."/locale.inc");
+ include_once($path_to_root . "/lang/" . $lang_code . "/locale.inc");
$code = $_SESSION['language']->code;
$hook_class = 'hooks_'.$code;
$Hooks[$code] = new $hook_class;
function activate_hooks($ext, $comp)
{
global $Hooks;
-
+
$hooks = @$Hooks[$ext];
if (!$hooks) {
$hookclass = 'hooks_'.$ext;
{
global $Hooks;
-
+
$result = null;
foreach($Hooks as $ext => $hook) {
if (method_exists($hook, $method)) {