<?php is also only for PHP whereas <? can be used for other languages, I believe.
<% also works in some cases for PHP I think, though that's the same for ASP, etc.
Twey, can you explain a bit more about:?Code:<?=something()?>
<?php is also only for PHP whereas <? can be used for other languages, I believe.
<% also works in some cases for PHP I think, though that's the same for ASP, etc.
Twey, can you explain a bit more about:?Code:<?=something()?>
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
Well; as I said before, <? and (I haven't mentioned this yet) <% works for php if it is enabled in the php.ini file. Otherwise, those above mentioned tags will not work (with PHP that is).
can you explain a bit more about:?Code:<?=something()?>is the same asCode:<?="This is a test" ?>
Hope this helps.Code:<?php echo "This is a test" ?>
Last edited by thetestingsite; 03-15-2007 at 03:38 AM.
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music." - Kristian Wilson, Nintendo, Inc, 1989
TheUnlimitedHost | The Testing Site | Southern Utah Web Hosting and Design
I get that... just like Twey's example.
But what's up with the '='? Does it set the implied output (beyond the <?) to the value? Or does it change the meaning of the <?= tag? Would it work with <?php=, etc.
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
Well, I just tested this:
and it didn't work.Code:<?php="This is a test";?>
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music." - Kristian Wilson, Nintendo, Inc, 1989
TheUnlimitedHost | The Testing Site | Southern Utah Web Hosting and Design
No, it's just a character used in the opening tag. It has no syntactical meaning, any more than <? is related to numerical comparisons and conditionals.Does it set the implied output (beyond the <?) to the value?No.Would it work with <?php=, etc.
Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!
Bookmarks