![]() |
How to use the asset helper - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: How to use the asset helper (/showthread.php?tid=46034) |
How to use the asset helper - El Forum - 10-15-2011 [eluser]Friedebarth[/eluser] So, in order to circumvent the trouble with loading CSS via HTML, which, apart from constantly refusing to work also makes it much harder for users to customise the skin, I downloaded the Assets helper. The question is, once I load the assets in my controller, like so: Code: public function index() How do I incorporate it into my view? My view currently looks like this: Code: <!DOCTYPE html> I tried doing this in the head: Code: <link rel="stylesheet" type="text/css" href="<?php $this->load->helper('asset'); echo text_output($stylesheet);?>" /> While doing that in the controller: Code: $data['stylesheet'] = css_asset('style.css'); But that just ended up blanking the whole page. So how do I do it properly? |