Re: [PHP] Quick questions ?=something?
Ryan A wrote: Hey all, Am a bit confused, from the time I learnt PHP (big thanks to this list for helping me) I have used something like this ?php echo $something; ? but when reading someone elses code I sometimes stumble accross this: ?php=something? is this 100% valid php? I have not found it in the manual... (also am not sure if the above example needs a $ symbol...) ?= $string ? means the same as ?php echo $string ? if short_open_tag is on -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Quick questions ?=something?
Yeah - it is valid. It is a short hand method for doing what you are doing. I don't know if it is in the manual, but it is in the certification guide. Respectfully, Ligaya Turmelle --- Life is a game... so have fun. --- www.PHPCommunity.org Open Source, Open Community Visit for more information or to join the movement Ryan A wrote: Hey all, Am a bit confused, from the time I learnt PHP (big thanks to this list for helping me) I have used something like this ?php echo $something; ? but when reading someone elses code I sometimes stumble accross this: ?php=something? is this 100% valid php? I have not found it in the manual... (also am not sure if the above example needs a $ symbol...) Thanks, Ryan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Quick questions ?=something?
?= $string ? means the same as ?php echo $string ? if short_open_tag is on ** It's perfectly valid PHP, I use it all the time on my own sites, but because it's one of those php.ini settings you have a 50/50 chance of finding on (or off!) you shouldn't rely on it unless you know the environment. Hey all, Thanks guys, I didnt know about any short_open_tag setting, I guess I'll just stick to my regular style coz i have no idea how the client/s php is setup plus if I move my own stuff to a different host it may not be so kind... Perfect answer to my Q, thanks! Cheers, Ryan -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.289 / Virus Database: 265.4.5 - Release Date: 12/3/2004 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Quick questions ?=something?
* Marek Kilimajer [EMAIL PROTECTED]: Ryan A wrote: Hey all, Am a bit confused, from the time I learnt PHP (big thanks to this list for helping me) I have used something like this ?php echo $something; ? but when reading someone elses code I sometimes stumble accross this: ?php=something? is this 100% valid php? I have not found it in the manual... (also am not sure if the above example needs a $ symbol...) ?= $string ? means the same as ?php echo $string ? if short_open_tag is on And since you cannot always count on that being on, it's more platform independent to use the ?php echo ; ? construct. -- Matthew Weier O'Phinney | mailto:[EMAIL PROTECTED] Webmaster and IT Specialist | http://www.garden.org National Gardening Association| http://www.kidsgardening.com 802-863-5251 x156 | http://nationalgardenmonth.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php