How to style PHP output?

Show php output as .HTML page?

  • i have a php page with html codes that they hold some php variables and echoes. but i want to separate them and put html code in standalone .HTML file. how to do this and call php variables/output in .html page?

  • Answer:

    you need to configure your web server to parse .html files for php code. If you just want to keep the code separate for tidiness you could also use a .php file as the base and use include('filename.htm') to insert the html code into the document

Web dr at Yahoo! Answers Visit the source

Was this solution helpful to you?

Other answers

I don't get what you're asking but if you're asking how to include an HTML file to appear on the php page then use... <?php include("yourhtmlfile.html"); ?> The above code will show everything from the 'yourhtmlfile.html' file as if it was a part of the php page, but the code is obviously on a completely different file.

J0nny3

<?php put your code here >? or <?php echo $variable;?>

Kelly

Related Q & A:

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.