By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,946 Members | 697 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,946 IT Pros & Developers. It's quick & easy.

PHP5 questions

P: n/a
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.replace($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.)
Jul 17 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Philipp Lenssen wrote:
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?)
Maybe you have magic_quotes_* set in php.ini

Try this with both php4 and php5

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

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


Don't know about your other questions :(
--
..sig
Jul 17 '05 #2

P: n/a
"Philipp Lenssen" <in**@outer-court.com> schrieb:
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?)
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.
Also, I was wondering when/ if PHP will include more object-oriented
functions, like $myString.replace($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.)
No.
Next, are there any plans to remove the "$" in front of variables?
No.
Will there be real private members/ functions in PHP5 when using
classes/ objects?


Yes.

Regards,
Matthias
Jul 17 '05 #3

P: n/a
Philipp Lenssen wrote:
I was wondering when/ if PHP will include more object-oriented
functions, like $myString.replace($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.)


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.

Jul 17 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.