Mantis Bugtracker
  

Viewing Issue Advanced Details Jump to Notes ] View Simple ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0003966 [Quercus] major always 03-24-10 22:11 06-19-12 14:55
Reporter Rogiel View Status public  
Assigned To nam
Priority normal Resolution unable to reproduce Platform
Status closed   OS
Projection none   OS Version
ETA none Fixed in Version Product Version 4.0.6
  Product Build
Summary 0003966: Setting array values using field name as another field
Description When setting an field into an array, Quercus set the entire array as the value of the field. Resulting in the loss of the array.

This problem is preventing vBulletin from posting new threads in Quercus.
Steps To Reproduce
Additional Information <?php
$test = new BugTest();

echo "Before Setting: ";
print_r($test->testField);
echo "
";

$test->set('a', 'A');
$test->set('b', 'B');

echo "After Setting: ";
print_r($test->testField);

class BugTest {
    var $field = "testField";
    
    function BugTest() {
        $this->{$this->field} = array();
    }
    
    function set($key, $value) {
        $this->{$this->field}[$key] = $value;
    }
}
?>
Attached Files  test.php [^] (408 bytes) 03-24-10 22:11

- Relationships

- Notes
(0005888)
nam
06-19-12 14:55

Unable to reproduce on trunk (upcoming 4.0.29).

Results:
Before Setting: Array
(
)

After Setting: Array
(
    [a] => A
    [b] => B
)
 

- Issue History
Date Modified Username Field Change
03-24-10 22:11 Rogiel New Issue
03-24-10 22:11 Rogiel File Added: test.php
03-24-10 22:16 Rogiel Issue Monitored: Rogiel
02-04-11 02:22 domdorn Status new => assigned
02-04-11 02:22 domdorn Assigned To  => domdorn
02-04-11 07:34 kdecherf Issue Monitored: kdecherf
05-11-11 14:58 dicr Issue Monitored: dicr
03-22-12 13:42 domdorn Assigned To domdorn =>
06-19-12 14:53 nam Assigned To  => nam
06-19-12 14:55 nam Status assigned => closed
06-19-12 14:55 nam Note Added: 0005888
06-19-12 14:55 nam Resolution open => unable to reproduce


Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
36 total queries executed.
29 unique queries executed.
Powered by Mantis Bugtracker