mozung Posted November 6, 2008 Share Posted November 6, 2008 I am following a tutorial and not getting everything. i have installed php and apache. Apache is running fine. I Created a file named phpinfo.php3 and add the following line to the file. <?phpinfo()?> Put the file in the Apache /var/www/html/. Started a web browser and go to http://127.0.0.1/phpinfo.php3. According to tutorial i should see a page that has some information about php and stuff. but all i see is text thing <?phpinfo()?>. also i see the index of my web pages when i go to main page of my website, i see "Index of /" . How can i see my actual main web page (blog) when i type in my url? ( it is showing the index.html, I have to click on it in order to see the webpage. ) any settings... Could you guys please help me out? thanks Quote Link to comment Share on other sites More sharing options...
neogranas Posted November 6, 2008 Share Posted November 6, 2008 Check your php.ini file for anything that would block phpinfo() Then check your apache config file (apache.conf or httpd.conf depending on your setup) for DirectoryIndex and I'd suggest changing it from .php3 to .php Quote Link to comment Share on other sites More sharing options...
mozung Posted November 8, 2008 Author Share Posted November 8, 2008 HI neo Thanks for reply, I changed extension to php and bingo, i was able to see informational page of php. Now I realize that i dont have php and php3 are different and require different installations. Moving to next problem. I want to see main page of my website when i open it, Not the index. How do i do that? thanks Quote Link to comment Share on other sites More sharing options...
neogranas Posted November 10, 2008 Share Posted November 10, 2008 Name the first page you want to come up index.php or index.html. If you want it to be something different, specify it in either your apache config or if you have .htaccess working you can specify there so it can be different in each directory. Quote Link to comment Share on other sites More sharing options...
CroNiX Posted November 11, 2008 Share Posted November 11, 2008 Try <?php phpinfo(); ?> instead of <?phpinfo()?> If that works short tags (<?) are probably turned off (like they should be) in your php.ini Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.