|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-11-27 12:51 UTC] sven at leon dot uia dot mx
[2003-11-28 20:35 UTC] sniper@php.net
[2003-12-04 02:23 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 21:00:01 2025 UTC |
Description: ------------ In a class I send an array $test as a parameter to a protected function. Then, if I try to access that array in any way in that function, suddenly the $this object contains the data of that array $test (!) Reproduce code: --------------- Sorry, cant make a short-and-clear reproducing code, but here I have a small code sample that actually caused the problem: (note that $this->params["source"] _IS_ an array) protected function get_body($css){ echo "B0 ("; print_r($this); echo ")<br>"; flush(); $retval=""; while(list($key, $cell_data)=each($this->params["source"])){ echo "B1 ("; print_r($this); echo ")<br>"; flush(); Expected result: ---------------- I will try to get a .zip together with the classes that seem to cause this problem. Actual result: -------------- B0 (table_key_value_a Object ( [params:protected] => Array ( [source] => Array ( [crc] => mBjsS50UkhAnxjWp [sid] => 75 [test_site] => 75,mBjsS50UkhAnxjWp ) [col headers] => Array ( [0] => Key [1] => Value ) [table header] => HTTP VARIABLES [css prefix] => debug [table header extra] => align='center' ) ) ) B1 (table_key_value_a Object ( [cell_data] => mBjsS50UkhAnxjWp [key] => crc ) )