Hi,

You could approach this differently. Instead have an array that you
set in the controller which the view looks for, if there's something
in it it adds the scripts. Works with cake as-is and doesn't break
[cake's] MVC.

// Controller
$this->set('ext_javascripts', array(
        'xhina/XinhaLoader.js?lang=pl&skin=green-look',
        'xhina/examples/XinhaConfig'
));

// VIn your layout
// NB: If you need in more than one layout, turn into an element
if (isset($ext_javascripts) & count($ext_javascripts)):
        foreach($ext_javascripts as $js):
                $this->Javascript->link($js);
        endforeach;
endif;

hth

Jon

-- 
jon bennett - www.jben.net - blog.jben.net

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to