jQuery get Function Not Returning Data

Posted by senfo on Stack Overflow See other posts from Stack Overflow or by senfo
Published on 2010-04-05T15:42:10Z Indexed on 2010/04/05 15:43 UTC
Read the original article Hit count: 295

Filed under:

I'm trying to use the jQuery get function to render the results of an HTML page in a div on my page. The result of the get function appears to be successful because the value of textStatus (in the following code block) is "success". The value of data, however, is always empty.

$(document).ready(function() {
  $.get('http://www.google.com', function(data, textStatus){
    $('#RSSContent').html(textStatus + ' ' + data);
  });
});

Any idea what I might be doing wrong?

Note: The final code will query an RSS feed, which I plan on transforming and rendering as HTML in the RSSContent div. I simply used http://www.google.com for testing purposes.

© Stack Overflow or respective owner

Related posts about jQuery