CI can't find my static HTML directory. |
[eluser]dtrenz[/eluser]
CI site structure: ci/ ci/system/ ci/system/css ci/system/js ci/system/img ci/system/html ci/application/... (controller/views/models/etc) My CI site can find the css, js, and img files fine using http://www.mysite.com/css/ but when i added a directory containing static html pages, i get a 404 when i try to access them via http://www.mysite.com/html/static.html What gives? Why would /css /js /img all work fine, but not a directory containing html pages? Any help MUCH appreciated. I could put them in the views directory, but i'd rather reserve the views directory for dynamic (php) pages, and not fill it with static html pages. Thanks -dan
[eluser]Michael Wales[/eluser]
Are you absolutely sure domain.com/css/style.css works? It's not domain.com/system/css/style.css? I can see no possible way CI could load that resource without the /system directory included in the URI. Are you using a helper of some sort that is dynamically generating the URI?
[eluser]dtrenz[/eluser]
oops! my actual site structure... Sorry. ci/ ci/css ci/js ci/img ci/html ci/system/ ci/system/application/
[eluser]Sean Murphy[/eluser]
Are you using mod_rewrite? If so, would you please paste all of the rules and conditions you are using.
[eluser]dtrenz[/eluser]
Thank you! I forgot I had an .htaccess file doing the work. RewriteEngine on RewriteCond $1 !^(index\.php|css|img|js|robots\.txt) RewriteRule ^(.*)$ /index.php/$1 [L] i just added |html to the rewritecond and it works! thanks again! -d
[eluser]bijon[/eluser]
Quote:Are you using mod_rewrite? If so, would you please paste all of the rules and conditions you are using.I am also agree with may be you are using mod_rewrite and do not add the html folder in your rules. Please check out here : Mod_rewrite Thanks Saidur Rahman
[eluser]dtrenz[/eluser]
yes. that's what i said. it was mod_rewrite. problem solved. thanks. ?> |
Welcome Guest, Not a member yet? Register Sign In |