quote:
Originally posted by Leroux
..., would it be possible to have multiple things determined by case?
Sure! Both PHP and JScript are case-sensitive when it comes to assigning a key to an array or object.
This allows you to do things like:
php code:
<?php
$test = array(
"foo" => "bar",
"FoO" => "cookie"
);
?>
and
js code:
var test = {
"foo" : "bar",
"FoO" : "cookie"
};
and both will give you an array/object with 2 values indexed by 2 keys.
This means that you can safely add a key to a PHP array, output it as JSON and retrieve it in JScript without any trouble with possibly similar key names.