How to deploy a server script?

I cannt get my php script to run on xammp onto my local host server.Apache is running fine and code has,what y?

  • I cannt get my php script to run on xammp onto my local host server.Apache is running fine and code has,what y? the code has no error,but i cannnot connect to my virtual local server to get my php script output on a virtural webpage what could be the reason..I saved the script into the htdocs file as .php,click on localhost to a webpage and nothing comes out from my php script what could be the problem???

  • Answer:

    Approach this systematically. First, can you get HTML pages to display? Try a really simple file, e.g. [HTML][BODY]Hello, World[/BODY][/HTML] Note: I'm using [] here to mean angle brackets because Yahoo blocks angle brackets! If not, what are the symptoms? Is the firewall blocking port 80? If HTML is OK, does a PHP file containing only HTML display? Try just renaming your simple file above to have a .php suffix. If that fails, maybe either PHP is not enabled in Apache (you don't say what platform you're on, but typically there'll be a mods-enabled folder which determines which modules apache loads). You may also need the AddType directive in Apache's config or a .htaccess file to make it run the PHP interpreter when it sees a .php file. If the simple file displays Hello, World, try a really simply bit of PHP (again, using [ to mean left-angle-bracket: you did remember the [?php didn't you?): [HTML][BODY] [?php echo 'hello, world'; ?] [/BODY][/HTML] Other things to do: check the Apache log files. There's an access log showing attempted connections and the result, and an error log which among other things will show you PHP errors.

Lisa L at Yahoo! Answers Visit the source

Was this solution helpful to you?

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.