Re: php doesn't work in html files

From: Date: Mon, 12 Jan 2004 17:43:19 +0000
Subject: Re: php doesn't work in html files
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-174351@lists.php.net to get a copy of this message
The facts is that EVERY html (php embeded or not) will be processed by PHP, which is totally unnecesary and a waste of time. The best practice is to append the .php extension to your php files. If your your working for production you must consider that your host provider won't agree to put his server to process every HTML as a PHP file. Manu. "Nico Berg" <nberg@gandalf.xs4all.nl> wrote in message news:IEEBJCNANAAAMKCGAEKLKENECHAA.nberg@gandalf.xs4all.nl... > Hi, > > It works. I decided to add .html to the list of extensions that will be > opend by php if asked for in apache. I understand here that it will take > more time before html files are processed? True? > > Thanks all, Nico Berg > > > -----Oorspronkelijk bericht----- > > Van: Nico Berg [mailto:nberg@gandalf.xs4all.nl] > > Verzonden: zondag 11 januari 2004 14:05 > > Aan: 'PHP General' > > Onderwerp: [PHP] php doesn't work in html files > > > > > > Hi there all, > > > > I use Apache version 1.3 and WIndows 2000. The site is not global but only > > local so I use the url http://localhost/index.html > > > > This index.html look's like this: > > > > <html> > > <body> > > This is a line > > </body> > > </html> > > > > <? > > echo "this is the second line"; > > ?> > > > > Output is: This is a line > > > > So the php part is not done at all. Is that right? I always believed php > > should work in html? > > > > Nico > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, visit: http://www.php.net/unsub.php > >

« previous php.general (#174351) next »