ID: 21886 Comment by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Feedback Bug Type: Class/Object related Operating System: Linux 7.2 PHP Version: 4.3.0 New Comment:
Ooops! I please forgive my mistake, in my last post, switch the call from: $bar->myecho("apple, orange"); to: $bar->myecho("apple", "orange"); Previous Comments: ------------------------------------------------------------------------ [2003-02-13 11:00:57] [EMAIL PROTECTED] Here is an example. class foo { // constructor, etc. function myecho($string1, $string2) { echo "String 1: " . $string1 . "\n"; echo "String 2: " . $string2 . "\n"; } }; $bar = new foo(); $bar->myecho("apple, orange"); Will output one of these 3 possibilities, at random (or so it seems:) String 1: apple String 2: orange String 1: orange String 2: String 1: String 2: Weird, eh? and rerunning the same code does not always give the same results. I guess it's clearer now. ------------------------------------------------------------------------ [2003-02-13 02:01:03] [EMAIL PROTECTED] Please provide a complete but short example that _clearly_ shows the problem. ------------------------------------------------------------------------ [2003-01-31 11:25:29] [EMAIL PROTECTED] With multiple parameters too, creates trouble. Using 2 parameters, sometimes only the second one is passed... as the first! ------------------------------------------------------------------------ [2003-01-26 07:52:28] [EMAIL PROTECTED] Hi @all, I have just mentioned a strange behaviour of PHP 4.3.0. At first of all: I have recompiled my hole config with PHP 4.2.3 and my program runs - without any change - fine ! Just have a look at the source: In index2.phtml: ----- $dummy="index2.phtml?step=printchecklist&mode=".$mode."&besuchid=".$besuch_id."&hid=".$form_hid."&sessvalid=".$s_sessvalid; if ($debug) @error_log("Redirect [origin=checklist] to: ".$dummy,0); $session->redirectTo($dummy); ----- in my Session-Class: ----- function redirectTo($pathInfo) { if ($this->debug) @error_log("SESSION [redirectTo]: Parameter: ".$pathInfo,0); [.......] } ----- and now my error-log: ----- [Sun Jan 26 14:24:43 2003] [error] Redirect [origin=checklist] to: index2.phtml?step=printchecklist&mode=&besuchid=&hid=16&sessvalid=951227295 [Sun Jan 26 14:24:43 2003] [error] SESSION [redirectTo]: Parameter: ----- The Parameter given to $session->redirectTo will not be recieved by the function. When I try this several times (my "$dummy" does NOT !!! change) after the second or the third try it works. Again - with 4.2.3 and excatly the same config *everything* is fine. Regards, Sebastian ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=21886&edit=1