4 Replies Latest reply on Jan 23, 2009 8:30 AM by Newsgroup_User

    php short tags

    jon@cmiwebstudio Level 3
      I never use them, but some people like them. I've come across some social networking frameworks that use them. What's the consensus on them?
        • 1. Re: php short tags
          Level 7
          Don't use them (I assume you mean "<?" instead of "<?php"). As I understand
          it, support for them has been removed in PHP5.

          --
          Murray --- ICQ 71997575
          Adobe Community Expert
          (If you *MUST* email me, don't LAUGH when you do so!)
          ==================
          http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
          http://www.dwfaq.com - DW FAQs, Tutorials & Resources
          ==================


          "jon@cmiwebstudio" <webforumsuser@macromedia.com> wrote in message
          news:glaqie$6br$1@forums.macromedia.com...
          >I never use them, but some people like them. I've come across some social
          >networking frameworks that use them. What's the consensus on them?

          • 2. Re: php short tags
            Level 7
            .oO(jon@cmiwebstudio)

            >I never use them, but some people like them. I've come across some
            >social networking frameworks that use them. What's the consensus on
            >them?

            Avoid them. They are unreliable (can be turned off on the server) and
            may cause problems with XML or other languages that use processing
            instructions starting with "<?". They will still be available in the
            coming PHP 6, but disabled by default.

            Micha
            • 3. Re: php short tags
              Level 7
              Murray *ACE* wrote:
              > Don't use them (I assume you mean "<?" instead of "<?php"). As I
              > understand it, support for them has been removed in PHP5.

              No, support for PHP short tags is still there, but their use is discouraged.

              --
              David Powers, Adobe Community Expert
              Author, "The Essential Guide to Dreamweaver CS4",
              "PHP Solutions" & "PHP Object-Oriented Solutions"
              http://foundationphp.com/
              • 4. Re: php short tags
                Level 7
                Thanks - I meant to say PHP6, but I see from Micha's post that they are
                still there although disabled....

                However, the bottom line appears to be "don't use them".

                --
                Murray --- ICQ 71997575
                Adobe Community Expert
                (If you *MUST* email me, don't LAUGH when you do so!)
                ==================
                http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
                http://www.dwfaq.com - DW FAQs, Tutorials & Resources
                ==================


                "David Powers" <david@example.com> wrote in message
                news:glcq4n$j00$1@forums.macromedia.com...
                > Murray *ACE* wrote:
                >> Don't use them (I assume you mean "<?" instead of "<?php"). As I
                >> understand it, support for them has been removed in PHP5.
                >
                > No, support for PHP short tags is still there, but their use is
                > discouraged.
                >
                > --
                > David Powers, Adobe Community Expert
                > Author, "The Essential Guide to Dreamweaver CS4",
                > "PHP Solutions" & "PHP Object-Oriented Solutions"
                > http://foundationphp.com/