Asset Helper
The Asset helper is really just a set of convenience functions that map to the Asset class. This was done because these functions may be used a lot on in view files and it is easier to type <?=img_path('my_img.jpg')?> instead of <?=$this->asset->img_path('my_img.jpg')?>. This helper is autoloaded.
This helper is loaded using the following code:
$this->load->helper('asset');
The following functions are available:
img_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->img_path().
css_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->css_path().
js_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->js_path().
swf_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->swf_path().
pdf_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->pdf_path().
media_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->media_path().
cache_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->cache_path().
captcha_path(['file'], ['module'], [is_absolute])
This function is the same as $this->asset->captcha_path().
assets_path(['file'], ['type'], ['module'], [is_absolute])
This function is the same as $this->asset->assets_path().
assets_server_path(['file'], ['type'], ['module'])
This function is the same as $this->asset->assets_server_path().
assets_server_to_web_path('file', truncate_to_asset_folder)
This function is the same as $this->asset->assets_server_to_web_path().
js('file', ['module'], params)
This function is the same as $this->asset->js().
css('file', ['module'], params)
This function is the same as $this->asset->css().
swf('file', 'id', 'width', 'height', other_options)
This function is the same as $this->asset->swf().