Failed to load resource: the server responded with a status of 403 (Forbidden) including css files and js libraries

StackOverflow https://stackoverflow.com/questions/14413260

Вопрос

I'm starting developing with codeigniter and I'm doing some few basically things to learn it on localhost with easyphp (I get bug with WAMP Server).

I create the folder "libraries/js/jquery-1.9.0.min.js", and "views/templates/css/style.css" and simply in header I include the files:

<link type="text/css" href="application/views/templates/css/style.css" rel="stylesheet" />
<script type="text/javascript" src="application/libraries/js/jquery-1.9.0.min.js"></script>

And the server return to me the follow errors:

GET http://127.0.0.1:8887/CodeIgniter_2.1.3/application/libraries/js/jquery-1.9.0.min.js 403 (Forbidden)
GET http://127.0.0.1:8887/CodeIgniter_2.1.3/application/views/tamplates/css/style.css 403 (Forbidden)

I searched for info and can be a permission problem in the files, but never happened to me before... and in a remote server I can access by ftp and change the permission, but how can I do it on localhost? If thats the problem..

Thanks in advance!

Это было полезно?

Решение

i found a solution here:

Where do I put image files, css, js, etc. in Codeigniter?

All people put those kind of files outside the codeigniter framework, i make it and now it works.

Thanks for the help.

PD: Now im fighting with the helper creation :D

Другие советы

If you are using macOS just right click on the folders in which your js and css files lie then click get info and tick the shared folder checkbox.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top