You are here: Re: building url from variable « All PHP « IT news, forums, messages
Re: building url from variable

Posted by Steve on 11/07/07 21:19

"J.O. Aho" <user@example.net> wrote in message
news:5peer1Fqra8vU1@mid.individual.net...
> Jerry Stuckle wrote:
>
>> Just like any other PHP statements - you need it within <?php and ?>. In
>> this case you want to display the value, so you echo it, i.e.
>>
>> <a href="http://www.widgets.com/<?php echo $var;?>">click here </a>
>>
>> Also,
>>
>> <?=$var?>
>>
>> is not good. It depends on short tags being on, and it isn't in a lot
>> (most?) hosts nowadays. The echo above works on any system.

every host i've used not only supports short tags, they'll turn them on if
off...further, you can turn them on yourself via ini_set.

> If I don't remember the log from the php6 "startup meeting", short tags
> on their way out from php, so yet another reason why use the full tags.

you remember correctly...doesn't change the fact that that is a STUPID
decision.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация