Welcome Guest, Not a member yet? Register   Sign In
assets folder not found after remove public from url
#1

I add/create new .htaccess and add to my root folder for remove public from url:

Code:
DirectoryIndex /public/index.php
RewriteEngine on
RewriteCond $1 !^(index\.php|images|assets|css|js|robots\.txt|favicon\.ico)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ ./public/index.php/$1 [L,QSA]

this solution work for me and remove public from url but when I add assets(css/js) in my header, codeigniter not found my assets folder ie:

Code:
<link rel="stylesheet" href="<?php echo base_url('assets/vendor/bootstrap/css/bootstrap.css'); ?>">

output is:

Code:
http://ci.local/assets/vendor/bootstrap/css/bootstrap.css">

This address not work(not found), how do can I fix this problem?
Reply




Theme © iAndrew 2016 - Forum software by © MyBB