I'm trying to insert an external website into a parent website. I'm using the following method to prepare the content:
jQuery.ajax({
type: "POST",
url: url,
xhrFields: {
withCredentials: true
},
crossDomain: true
}).done(function (result) {
...
embedDiv = document.getElementById("embedDiv");
embedDiv.innerHTML = result;
)}
Now, while all the CSS and Javascript Code is working perfectly, it also takes effect on all the elements of the parent page. Is there a way to restrict all the loaded sources to only work within the div container "embedDiv"?
Thanks for any clues!