[FX.php List] Embed php into HTML or vice versa?

DC dan.cynosure at dbmscan.com
Thu Aug 31 21:03:08 MDT 2006


On Aug 31, 2006, at 10:22 PM, Kevin Futter wrote:

> The PHP manual itself recommends against them, and they can cause  
> all sorts of problems in XML environments, where they can (do) look  
> like an XML prolog.

True. But, the manual says that you shouldn't use them if you are  
developing libraries or code to run on other people's machines. For  
your own use on your own systems it is a good tool to have available  
- especially working with web designers.

According to the PHP manual, your comment about XML also seems to  
apply to XHTML though I am not sure why the presence of short PHP  
tags in PHP code would make a whit of difference to the validity of  
XHTML output by said code. Since you so kindly clarified the most  
recent XHTML question would you mind explaining why short tags would  
impinge on XHTML? (I understand the problem with XML)

  For reference, here is the manual's quote you mentioned about the  
desirability of short tags:
Note: Using short tags should be avoided when developing applications  
or libraries that are meant for redistribution, or deployment on PHP  
servers which are not under your control, because short tags may not  
be supported on the target server. For portable, redistributable  
code, be sure not to use short tags.

Cheers,

dan


More information about the FX.php_List mailing list