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
Post a Comment