Where is it acceptable to put css folders and image file folders? I was thinking inside the view folder? However the controller always reroutes the path to the base url so I
No one says that you need to modify the .htacces and add the directory in the rewrite condition. I've created a directory "public" in the root directory alongside with "system", "application", "index.php". and edited the .htaccess file like this:
RewriteCond $1 !^(index\.php|public|robots\.txt)
Now you have to just call <?php echo base_url()."/public/yourdirectory/yuorfile";?>
You can add subdirectory inside "public" dir as you like.
I just wanted to add that the problem may be even simpler -
I've been scratching my head for hours with this problem - I have read all the solutions, nothing worked. Then I managed to check the actual file name.
I had "image.jpg.jpg
" rather than "image.jpg
".
If you use $ ls public/..path to image assets../
you can quickly check the file names.
Sounds stupid but I never thought to look at something so simple as file name given the all the technical advice here.