Re: Browsers don't see PHP scripts?!

From: Date: Wed, 30 Aug 2000 08:00:36 +0000
Subject: Re: Browsers don't see PHP scripts?!
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-14340@lists.php.net to get a copy of this message
Then I'm lost someplace....from the manual...a serious possibilty Example 5-1. Ways of escaping from HTML 1. <? echo ("this is the simplest, an SGML processing instruction\n"); ?> 2. <?php echo("if you want to serve XML documents, do like this\n"); ?> 3. <script language="php"> echo ("some editors (like FrontPage) don't like processing instructions"); </script> 4. <% echo ("You may optionally use ASP-style tags"); %> <%= $variable; # This is a shortcut for "<%echo .." %> The first way is only available if short tags have been enabled. This can be done via the short_tags() function, by enabling the short_open_tag configuration setting in the PHP config file, or by compiling PHP with the --enable-short-tags option to configure. The fourth way is only available if ASP-style tags have been enabled using the asp_tags configuration setting. ken TV Karthick Kumar wrote: > > Not all servers understand all php tags ?. > As far as I know, once you have PHP engine installed and running in your > webserver, all the php tags WILL be understood by the servers and will be > executed properly. > '<?' is the tag reference for PHP tags which can be modified / changed by > changing the PHP configuration, including the .php file extension. It's not > a MUST that all the php files should have .php as it's file extension. > > ~ Karthick > > > > > If I'm not mistaken, not all servers understand all php tags. > > > > For example, some servers may accept <?php others may not. > > For the server to understand <? tags I think short tags have to be > > enabled.... another tag ref <%, I think requires something to be enabled > > ref asp tags...... > > > > It should be somewhere in the manual re: syntax, in the intro section. > > > > Ken > > > <head> > > > <title>Example</title> > > > </head> > > > <body> > > > <B> PHP test </B> > > > <?php echo "Hi, I'm a PHP script!"; ?> > > > > > > <? echo ("this is the simplest, an SGML processing instruction\n"); > ?> > > > > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > > For additional commands, e-mail: php-general-help@lists.php.net > > To contact the list administrators, e-mail: php-list-admin@lists.php.net > >

« previous php.general (#14340) next »