Welcome Guest, Not a member yet? Register   Sign In
What is the best way to implement the Asset Helper?
#2

[eluser]pzntec[/eluser]
I would suggest having an asset directory as such:
-application
-system
-asset
--css
--js
--img

Then within the head section of your html have:
Code:
<base href="<?php echo base_url().'asset/'; ?>" />

This way you would not have to reference each asset in your main html code.

Also, if you have an .htaccess file, have your asset directory ignored:
Code:
RewriteCond $1 !^(index\.php|asset|robots\.txt)
*Notice the |asset|

So far this method has worked best for me.


Messages In This Thread
What is the best way to implement the Asset Helper? - by El Forum - 06-02-2013, 02:14 PM
What is the best way to implement the Asset Helper? - by El Forum - 06-02-2013, 02:50 PM
What is the best way to implement the Asset Helper? - by El Forum - 06-02-2013, 03:33 PM
What is the best way to implement the Asset Helper? - by El Forum - 06-03-2013, 01:29 AM
What is the best way to implement the Asset Helper? - by El Forum - 06-03-2013, 09:13 AM



Theme © iAndrew 2016 - Forum software by © MyBB