ify Posted June 2, 2010 Share Posted June 2, 2010 please am a new member of php freaks. i have been using http://localhost/index.php to run php codes,now i can't view the page again. it comes with error message. error 404 this url cannot be found. but the index.html is till running. can anyone help me please? thanks ify Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/ Share on other sites More sharing options...
trq Posted June 2, 2010 Share Posted June 2, 2010 Does this file 'index.php' exist within your servers document root? Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066583 Share on other sites More sharing options...
Mchl Posted June 2, 2010 Share Posted June 2, 2010 How about http://127.0.0.1/index.php ? Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066591 Share on other sites More sharing options...
mattal999 Posted June 2, 2010 Share Posted June 2, 2010 You're probably not running your WAMP package. The reason that index.html works is because it doesn't require Apache or IIS to run locally, as there is no code to compile. Make sure that you have started your WAMP package (such as phpdev) and that Apache is running. Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066594 Share on other sites More sharing options...
Adam Posted June 2, 2010 Share Posted June 2, 2010 Quote You're probably not running your WAMP package. The reason that index.html works is because it doesn't require Apache or IIS to run locally In which case he wouldn't get a 404 error returned from the web server. Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066596 Share on other sites More sharing options...
ify Posted June 2, 2010 Author Share Posted June 2, 2010 please am a new user of the software how am going to check the index.php from the root. thanks ify Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066603 Share on other sites More sharing options...
Adam Posted June 2, 2010 Share Posted June 2, 2010 The document* root, what's the path to the directory in which you keep your server documents? Often it's named "htdocs" or "public_html", or something along those lines. Find that, look in the directory, and check to see if index.php is there. Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066608 Share on other sites More sharing options...
ify Posted June 2, 2010 Author Share Posted June 2, 2010 yes i can find it. what else to do Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066614 Share on other sites More sharing options...
Adam Posted June 2, 2010 Share Posted June 2, 2010 So it's in the right dir. What are the permissions are on the file? Could you post the exact error you get when you try to access the it through the browser? Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066618 Share on other sites More sharing options...
ify Posted June 2, 2010 Author Share Posted June 2, 2010 sorry is not there. i mean the index.php. error, The requested URL /index.php was not found on this server. Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066623 Share on other sites More sharing options...
Adam Posted June 2, 2010 Share Posted June 2, 2010 Well if it's not there, that's why you're getting the error? Do you have another copy of it anywhere? Check your recycle bin too. Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066628 Share on other sites More sharing options...
ify Posted June 2, 2010 Author Share Posted June 2, 2010 i can only find in it in one of the folders in wamp Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066640 Share on other sites More sharing options...
Adam Posted June 2, 2010 Share Posted June 2, 2010 ...Which folder? Could show the paths as opposed to just naming them. Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066645 Share on other sites More sharing options...
Andy-H Posted June 2, 2010 Share Posted June 2, 2010 Shold be wamp\www Link to comment https://forums.phpfreaks.com/topic/203624-how-run-a-code-on-local-browser/#findComment-1066646 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.