PHP5 questions

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts

  • Keith Bowes
    Guest replied
    Re: PHP5 questions

    Philipp Lenssen wrote:[color=blue]
    > I was wondering when/ if PHP will include more object-oriented
    > functions, like $myString.repla ce($find, $replaceWith). (I sometimes
    > wonder if I need to use the first or second or third parameter or what
    > and it takes some more seconds to check PHP.net.)
    >[/color]

    The developers have said that PHP will remain a procedural language.
    However there's nothing preventing you from writing a String class.
    Maybe it would be added to PEAR.

    Leave a comment:


  • Matthias Esken
    Guest replied
    Re: PHP5 questions

    "Philipp Lenssen" <info@outer-court.com> schrieb:
    [color=blue]
    > I noticed there's an error in PHP when it receives form data. It seems
    > to precede various characters with "\". I was wondering if that's about
    > to get fixed in PHP5, or already is fixed in PHP4? (Or is this somehow
    > not an error?)[/color]

    No, this is no error. You might have activated magic_quotes in your
    php.ini. If you want to continue this, then use stripslashes() with the
    incoming data.
    [color=blue]
    > Also, I was wondering when/ if PHP will include more object-oriented
    > functions, like $myString.repla ce($find, $replaceWith). (I sometimes
    > wonder if I need to use the first or second or third parameter or what
    > and it takes some more seconds to check PHP.net.)[/color]

    No.
    [color=blue]
    > Next, are there any plans to remove the "$" in front of variables?[/color]

    No.
    [color=blue]
    > Will there be real private members/ functions in PHP5 when using
    > classes/ objects?[/color]

    Yes.

    Regards,
    Matthias

    Leave a comment:


  • Pedro Graca
    Guest replied
    Re: PHP5 questions

    Philipp Lenssen wrote:[color=blue]
    > I noticed there's an error in PHP when it receives form data. It seems
    > to precede various characters with "\". I was wondering if that's about
    > to get fixed in PHP5, or already is fixed in PHP4? (Or is this somehow
    > not an error?)[/color]

    Maybe you have magic_quotes_* set in php.ini

    Try this with both php4 and php5

    <?php
    $mq = array('magic_qu otes_gpc', 'magic_quotes_r untime');
    foreach ($mq as $x) {
    echo "$x is ", ini_get($x), "<br/>\n";
    }
    ?>

    [color=blue]
    > [...]
    > Thanks for any info. (I read through the changes log of PHP5, by the
    > way.)[/color]

    Don't know about your other questions :(


    --
    ..sig

    Leave a comment:


  • Philipp Lenssen
    Guest started a topic PHP5 questions

    PHP5 questions

    I noticed there's an error in PHP when it receives form data. It seems
    to precede various characters with "\". I was wondering if that's about
    to get fixed in PHP5, or already is fixed in PHP4? (Or is this somehow
    not an error?)

    Also, I was wondering when/ if PHP will include more object-oriented
    functions, like $myString.repla ce($find, $replaceWith). (I sometimes
    wonder if I need to use the first or second or third parameter or what
    and it takes some more seconds to check PHP.net.)

    Next, are there any plans to remove the "$" in front of variables?

    Also: will XPath be supported internally/ by standard libraries (I use
    a special library not part of PHP and it could be a little faster)?

    Will there be real private members/ functions in PHP5 when using
    classes/ objects? (And any plans to drop "$this->", not that it's
    really bad?)


    Thanks for any info. (I read through the changes log of PHP5, by the
    way.)
Working...