Home  |  Linux  | Mysql  | PHP  | XML
From:Jan G.B. Date:Thu Mar 18 17:37:39 2010
Subject:Re: Re: PHP in HTML code
2010/3/18 Ashley Sheridan <ash@ashleysheridan.co.uk>

> On Thu, 2010-03-18 at 18:09 +0100, Jan G.B. wrote:
>
> 2010/3/18 Ashley Sheridan <ash@ashleysheridan.co.uk>
>
> > I'd rather have short tags turned off than remember each time that I have
> > to keep breaking up the < and ?php before I output it in-case the parser
> > gets confused.
> >
>
> You don't need to break anything up. It's perfectly valid and without
> problems:
>
> <?php echo '<?xml version.... ?>'; ?>
>
>
> What about this:
>
> <?xml version="1.0">
> <?php
>
>
It's confusing! =)


> That would break with short tags turned on. I often use this sort of code
> in my Ajax server stuff. I don't want to have to use PHP to echo out what
> would work on a normal setup.
>

I can understand it. But I think it's nonsense to output one line of "text"
(prolog) and then start with <?php - while arguing that the first line of
PHP should not be an echo. Where's the point?



>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>

Navigate in group php.general at sever news.php.net
Previous Next


Your recent visits
Re: [PHP] Spreadsheet_Excel_Reader problem
pecl install geoip doesnt work. Warning: opendir(/var/tmp/pear-build-root/install-geoip-1.0.7//var/www/pear):
=?utf-8?B?UmU6IFJlOiBJc3N1ZSB3aXRoIGJsb2NrZWQgc29ja2V0IHN0cmVhbQ==?=
cvs: pecl /llvm INSTALL



  
© No Copyright
You are free to use Anything, but please consult your advocate before doing so as this website
also list content from other sources which may be copyrighted.
Site Maintained by Zareef Ahmed
Powered By PHP Consultants