PDA

View Full Version : Load html into div and unload



Lamo
07-09-2013, 06:26 PM
1) Script Title: Load html into div and unload

2) Script URL (on DD):

3) Describe problem:
This is my script


$(document).ready(function() {
$('a.container').click(function(e) {
e.preventDefault();
e.stopPropagation();

$('#container')
.hide()
.load(this.href, function()
{
$(this).fadeIn(1500);
});
});
});

and it's perfect, loads external html (just plain text) into div and then change it when I click on another link. Also when I click back on the first link, it load back first html.

Problem become, when I add some script into those external html (like some script for sliders with images). It won't load back first html.

Do I maybe need to unload first and then load another content? How can I do this?

Thanks

ajfmrf
07-10-2013, 01:10 AM
Please post a link to the page on your site that contains the problematic script so we can check it out.

And if you are using a dd script you are supposed to give a link to it(if you are using a dd script as I said-)