Seen this used:

echo _("This is a test.");

What's this do? 🙂

    _echo is used in some programming languages to echo the contents of a file. (I'm pretty sure XML uses this).

    I don't believe it does anything in PHP (except spit out an error probably 😉).

    -Kaz

      Not _echo

      echo _("This one");

      =)

      It's actually used quite extensively in the Horde project, but I don't know what it does.

        what you gave an example to is nothing more than a call to a function called "_" underscore, take this for example

        <?
        function _()
        {
        echo "This is a test.";
        }
        echo _();
        ?> 

        that will echo // This is a test.

        what you supplied will simply cause a fatal error, cuz you are trying to call an undefined function

          Well, that makes sense...

          what you supplied will simply cause a fatal error, cuz you are trying to call an undefined function

          Actually, making a little script:

          <?php
          echo _("test");
          ?>

          Works fine. Odd.

            not in a file alone with nothing else in it, it doesn't work

              Works fine for me... apache 2.0.40, PHP 4.2.3.

                hmmm...i would think that it shouldn't, to you have all error reporting turned off

                  error_reporting = E_ALL & ~E_NOTICE

                  From /etc/php.ini.

                    Indeed... thanks for the help! Glad I got the answer I was looking for.

                    Resolved. 🙂

                      ya wanna mark it resolved, there is a link below the posts

                        Write a Reply...