What steps will reproduce the problem?
1. $div = pq('<div>old text</div>')->text('0');
2. echo $div;
What is the expected output? What do you see instead?
Expected "<div>0</div>", got "old text". The old text value is returned
instead of updating the text.
What version of the product are you using? On what operating system?
phpQuery version 0.9.5.304, Windows XP
Please provide any additional information below.
html('') and html('0') both work as expected.
Changing line 2221 in phpQueryObject.php from
if ($text)
to
if (isset($text))
works as expected.
Original issue reported on code.google.com by mcdesig...@gmail.com on 2 Dec 2008 at 6:41
Original issue reported on code.google.com by
mcdesig...@gmail.com
on 2 Dec 2008 at 6:41