JS array to PHP
===

I have a string containing a Javascript array the next way:

    $array = "var Array = [
                 { 'a' : 'val1', 'b': 1},
                 { 'a' : 'val2', 'b': 2}
    ];";

How can I convert this string to a PHP array in the next structure:

    $array[0] => array('a' => 'val1', 'b' => 1)
    $array[1] => array('a' => 'val2', 'b' => 2)

Thanks

