webgirl29
asked on
Jquery Tools - Overlay - Load External Page
Hello. I downloaded the Demo from JQuery Tools here http://jquerytools.org/dem os/overlay /external. html and I'm having trouble. Basically, I went back to the very beginning with the code I downloaded and cannot figure out why it DOES load an external page in the Demo on the site, but DOES NOT when I download the demo to my personal workspace. I've attached the demo here.
Made a modification to the overlay color, but that's it. Can you help me figure out how to get the external pages to load in the <div> container? See ZIP file attached. jquery-overlay.zip
Made a modification to the overlay color, but that's it. Can you help me figure out how to get the external pages to load in the <div> container? See ZIP file attached. jquery-overlay.zip
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
XMLHttpRequest will be blocked when the page you are referencing is ON A DIFFERENT SERVER. So, mysite.com cannot use $.load("http://google.com")
It really depends on your intent, but ultimately this is a HUGE security hole if it were allowed. People do iFrames to show redirected content, or use JSONP services which ARE allowed to come from external domains to feed data rather than a "page".
It really depends on your intent, but ultimately this is a HUGE security hole if it were allowed. People do iFrames to show redirected content, or use JSONP services which ARE allowed to come from external domains to feed data rather than a "page".
ASKER
Ok, understood. Thank you for the quick response. So as long as it's on the same server, I should be fine. If I was pulling content from a different "sister" company website that's on the same server (different domain though), you're saying that will work as well? Just curious.
Good question re: Domain versus Server. I am actually not sure, but it would be easy to test. My guess is it WILL NOT work.
ASKER
Ok, not a problem. I may test that out, but not a requirement for me at this time. Was just curious. Thank you for your assistance and feedback. Much appreciated!
ASKER