javascript - jQuery .load(): loading a div when click -


i achieve when clicking in image, in div image is, div other content .html loaded, can't done.

if do, following, works perfectly:

$('#windows_link').click(function(){         $('#apps_container').html("hi!");     }); 

but if following, not work; doesn't actually:

$('#windows_link').click(function(){         $('#apps_container').load('windows_apps.html #apps_container');     }); 

any help, please?

thanks lot in advance!

when you're local other html path treated another domain in browsers (chrome on list). means ajax request (what .load() underneath) attempt blocked same origin policy.

what have work fine...just not locally, in chrome.

you can verify testing in browser firefox, or launching chrome with command line switch disable safety feature (only testing!, turn off after):

chrome.exe --disable-web-security 

Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -