Skip to content Skip to sidebar Skip to footer

Can't Get Div Content From Jquery Object After Ajax Request

Here is my jquery: $.ajax({ url: hash, success: function(data){ var thePage = $(data); alert(data); $('#slider_menu').html($('div#menu_bg', thePage).htm

Solution 1:

Can you try ?

   $.ajax({
    url: hash,
        success: function(data){
            $('#slider_menu').html($(data).filter('div#menu_bg').html());
        }
    });

Hope this helps.

Solution 2:

What about finding the parent of div#wrapper?

Solution 3:

You could try start from body tag.

$("body").next()

next() give you the imediately tag.

Solution 4:

Had to change the returned code... there was no answer - it must be a bug, or similar.

Solution 5:

Try

$('#slider_menu').html($(data).find('div#menu_bg').html());

Cheers!

Post a Comment for "Can't Get Div Content From Jquery Object After Ajax Request"