Alexander Beninski
Alexander Beninski

Reputation: 817

Codeigniter subdomain issue

Okey guys i have my project deployed to a subdomain folder on my server and when I try to access that subdomain -> new.mysite.com code igniter loads the 404 not found page.

It works perfectly on localhost and on a server without subdomain for example mysite.com.

Any ideas? I tried to change the base_url to new.mysite.com and it doesnt work.

Is there a way to see what url it is realy trying to load I don't know. I'm desperate i guess i have to touch the routes but what to write there?

Upvotes: 0

Views: 2341

Answers (1)

Teun van Vegchel
Teun van Vegchel

Reputation: 192

This probably hasn't got to do with your base_url setting. If your index page doesn't get loaded, something else is probably wrong.

Are you getting CodeIgniter's 404 message, or Apache's?

In case you're getting CodeIgniter's 404 message (even for your default index page), chances are CodeIgniter isn't able to parse the relevant URL section correctly. In that case: please check (or provide us with) your .htaccess file (in case you're using mod_rewrite).

On a personal note: I've experienced such problem before too. After much fiddling and cursing, I eventually decided to just dive into CodeIgniter's system files (I believe it was system/core/CodeIgniter.php) and to alter the piece of code that reads the relevant piece of the url.

Upvotes: 1

Related Questions