title: PHP creates a Json that ajax cant read
body: <p>I have a php command that like this. </p>
  
  <pre><code>  $query = "SELECT * FROM $table WHERE user_id = 0";
    $results = mysql_query($query)or die(mysql_error());
    while($row = mysql_fetch_assoc($results)){
  
    $values []= $row;
  
    }
    echo json_encode($values);
  </code></pre>
  
  <p>This creates a json array like this</p>
  
  <pre><code>[{"id":"1","name":"amazon.com","url":"http:\/\/amazon.com","time":"5","credits":"0","user_id":"0"},{"id":"2","name":"google.com","url":"http:\/\/google.com","time":"4","credits":"0","user_id":"0"}]
  </code></pre>
  
  <p>This json array than becomes part of a ajax response Text on a different page.</p>
  
  <pre><code>   var ajaxd = ajax();
          ajaxd.onreadystatechange = function(){
  
          if(ajaxd.readyState == 4){
           var nse = eval('('+ajaxd.responseText+')');
            alert(nse['url']);
          }
        }
  </code></pre>
  
  <p>The problem is.. The alert is always being undefined. What am I doing wrong?</p>