Page 1 of 1

loading a script to Apache

PostPosted: 02. April 2007 18:34
by fresher
Hello people, I have recently installed xampp on my linux box but having problems getting things to work write. I want to upload a small php script to the apache server and be able to access it from my web browser. Does anyone know how to do this please. many thanks in advance

PS: With Wamp i normally copy my php script into a 'www' folder and access it from a web browser typing something like this: http://localhost/www/script_name....

PostPosted: 02. April 2007 18:38
by Wiedmann
I want to upload a small php script to the apache server and be able to access it from my web browser.

Just put your script "foo.php" into the directory "/opt/lampp/htdocs/" and you can access it with "http://localhost/foo.php".

PostPosted: 11. April 2007 11:51
by morar
I put my php script in htdocs, but I still get a message about error like this: Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0

Fatal error: Unknown: Failed opening required '/opt/lampp/htdocs/exdatis/first.php' (include_path='.:/opt/lampp/lib/php') in Unknown on line 0

I'am also using Ubuntu. :(

PostPosted: 11. April 2007 12:28
by Wiedmann
I put my php script in htdocs,

Well, for the test you have only used a script like this?
Code: Select all
<?php echo "I'm here :-)"; ?>

PostPosted: 12. April 2007 12:51
by morar
Sorry, I'am a very stupid man!!!
Everything is OK, but if you just copy php script into folder htdocs you must give the privilegies to other users for view.
For other beginers see man chmod in command line tools. :oops: :oops: :oops: