[eluser]slowgary[/eluser]
I'm not sure but couldn't you just put the javascript into the view that requires it?
You could also just define() a constant in each view:
Code:
if(!defined('header_view'))
{
define('header_view');
}
Then in another view...
Code:
if(defined('header_view'))
{
echo "< script type='text/javascript' src='library.js' >< /script >";
}
You can also use get_defined_constants(), which will return an associative array of defined constants.