Re: Displaying PHP-File

From: Date: Thu, 10 Aug 2000 07:55:27 +0000
Subject: Re: Displaying PHP-File
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-11083@lists.php.net to get a copy of this message
Martin Thoma wrote: > > Hello ! > > I have a page with a form. The form is build with php4, the page > contains HTML-Code and PHP-Code: > > <HTML> > ... some html-code > > <SCRIPT LANGUAGE="PHP"> > include "ShowForm.php"; > </SCRIPT> Just qurious, why not use "<?php" and "?>"? > ... some other html-code > </HTML> > > The form is posted to another php-script. If there is an error, this > script should display the file above again with an error-message. > > But when reading-in the file above and printing it, the PHP-Section is > not executed and the form is not displayed. "include" needs parantheses (sp?): include("ShowForm.php"); (strangely enough, the first example at "http://www.php.net/manual/function.include.php" has none... weird). Also note that ShowForm.php will start out in HTML mode. /Niklas

« previous php.general (#11083) next »