6

Why the following jQuery code doesn't work? I put a div element in the body already. Thanks!

$(document).ready(function(){
  $("div").load("http://www.pagetutor.com/index.html");
});
1
  • 2
    Also, are you sure you mean to load the content into every <div> on the page at once?! Commented Apr 19, 2009 at 2:42

1 Answer 1

13

Without having more info:

You can't load remote domain content unless it's json content.

This is a browser restriction.

Sign up to request clarification or add additional context in comments.

Comments