I am currently using Codeignitor as my PHP framework with XAMPP. I always keep all my files in c:/xampp/htdocs/.

The settings are working fine in my own localhost machine. But when I load the same project in other machines connected via a router only the hypertext that is within the Codeignitor framework i.e inside application and system folder are getting displayed. But the external sources like stylesheets, images are not being displayed.

On other machines I can access the project via the following URL.


And on my own machine I can access it via http://localhost/project_route

But the strange thing is that projects that do not use codeignitor are doing fine in both my machine and the others locally connected via router.

I think the problem is arising bacause due to the file permissions of the external resources(css,images etc.).

can this problem be solved with .htaccess or any other mechanism?

OS:windows 7 I appreciate any help towords this.

2 Answers 2


I found out my own answer to my question.... The problem was related to the base_url settings.

I correct this problem by switching from:

http://localhost/project_folder to http://my_ip/project_folder

This was the reason why only resources were loading on my machine and not other machines.

Thanks everyone who viewed my question and those who tried to answer.


I always access resources like this

 <?= base_url(); ?>css/style.css

and i would recommend it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.