Asset loader based on @dongilbert asset loader ( https://gist.github.com/4205674 )
ELHtml::asset('style.css');
Checks in this order (when called inside com_helloworld component):
/templates/MY_TEMPLATE/css/com_helloworld/style.css
/media/com_helloworld/css/style.css
ELHtml::asset('slide.js', 'mod_menu');
Checks in this order:
/templates/MY_TEMPLATE/js/mod_menu/slide.js
/media/mod_menu/js/slide.js
echo ELHtml::asset('search.png', 'mod_product_search', array('alt' => 'This is the alt text'));
Checks in this order:
/templates/MY_TEMPLATE/images/mod_product_search/search.png
/media/mod_product_search/images/search.png