parsing php in .html files

Problems with the Windows version of XAMPP, questions, comments, and anything related.

parsing php in .html files

Postby viraynaud » 25. March 2010 10:28

Hi,

First, sorry for my English because I'm French...
For my website I use a CMS working with html skeletons. I can explain if the word "skeleton" is wrong... So the page .php loads a skeleton, and it's also possible to write PHP in .html files. It works online but not on my PC with xampp... I read ( here : http://www.webmasterworld.com/php/3432766.htm) that there was something to edit in httpd.conf to parse PHP in htlml files but it doesn't works, I think I haven't done the right thing...

what sould I modify to parse php in html files please? thanks!
viraynaud
 
Posts: 2
Joined: 25. March 2010 10:14

Re: parsing php in .html files

Postby Nobbie » 25. March 2010 11:07

I think you problem is NOT the HTML file, but that you use short tags "<?" instead of full tags "<?php". Remember: also "<?=$variable?>" is a short tag.

Either change your tags into long tags or edit php.ini and set "short_open_tag" to 1 (or "On", see php.ini). And restart Apache after changing php.ini
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: parsing php in .html files

Postby viraynaud » 25. March 2010 11:13

well, I've verified that... but I both set short_open_tag to yes, and always use "<?php", never "<?" .... thanks for your answer!
viraynaud
 
Posts: 2
Joined: 25. March 2010 10:14


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 109 guests