Welcome Guest, Not a member yet? Register   Sign In
index.php
#1

[eluser]01010011[/eluser]
Hi,
I just extracted CodeIgniter into XAMPP's htdocs folder. However, the installation instructions state that I should put CodeIgniter's index.php at the root. However, XAMPP's index.php is already there. So what should I do? Any assistance will be helpful. Thanks.
#2

[eluser]danmontgomery[/eluser]
The index.php that comes with a xampp installation is just a file to test that PHP is working... It can and should be deleted.
#3

[eluser]01010011[/eluser]
Thanks for your reply noctrum. When I removed XAMPP's index.php and replaced it with CodeIgniter's index.php, and navigated to it using the following url

Quote:http://127.0.0.1/index.php

I got the following error messages:

Quote:Warning: require_once(C:\xampp\htdocs/system/codeigniter/CodeIgniter.php) [function.require-once]: failed to open stream: No such file or directory in C:\xampp\htdocs\index.php on line 115

Fatal error: require_once() [function.require]: Failed opening required 'C:\xampp\htdocs/system/codeigniter/CodeIgniter.php' (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\index.php on line 115

Line 115 in the index.php states:

Quote:require_once BASEPATH.'codeigniter/CodeIgniter'.EXT;

But when I also put the "system" folder at the root as well, I got the CodeIgniter Welcome page. But the instructions did not say to do this so what should I do?

But when I put back and navigate to the original place where the index.php was

Quote:http://127.0.0.1/codeigniter_1.7.2/index.php

I get the CodeIgniter Welcome page with no errors. What should I do?
#4

[eluser]danmontgomery[/eluser]
For a default installation, /system and index.php should be in the same folder. If they are in your webroot, you would accesss the site at http://localhost/index.php, if they are in a folder in the webroot (codeigniter_1.7.2/ for example), you would access the site at http://localhost/codeigniter_1.7.2/index.php
#5

[eluser]01010011[/eluser]
Thanks for your reply. What puzzles me is that CodeIgniter clearly stated to only place the index.php in the root, not system and index.php, so as a result, I felt that something is not working as it should. I don't understand, am I wrong?
#6

[eluser]Blaze Boy[/eluser]
I noticed somethig!! you really don't have to extract codeigniter at the root of the host? you can extract it to
Code:
htdocs/codeigniter
for example
#7

[eluser]01010011[/eluser]
Thanks for your reply Blaze Boy. Yeah, thats what I did and it works like that. I was just wondering why it did not work the way CodeIgniter said it will work, i.e. 127.0.0.1/
#8

[eluser]01010011[/eluser]
Sorry guys, I finally understand, they meant to extract the contents of the codeigniter folder to the htdocs folder. Thanks for your help noctrum and Blaze Boy.




Theme © iAndrew 2016 - Forum software by © MyBB