Jebadiah Posted June 22, 2010 Share Posted June 22, 2010 I am trying to get the <object> tag's innerHTML from firebug using JQuery, but when I run $('object').html(); from Firebug it always returns null. I am unable to set attributes for the tag too: $('object').attr('abcd', 'efgh'); The same happens with embed tags as well. Does anyone know why? What are some alternatives to get/set those attributes of object tags? Any inputs would be useful. Thanks! Link to comment Share on other sites More sharing options...
0 DeathLace Posted June 22, 2010 Share Posted June 22, 2010 Don't mean to be rude or anything, but you are referencing the jQuery library first right? Is it possible to post the code of the webpage? Link to comment Share on other sites More sharing options...
0 Jebadiah Posted June 23, 2010 Author Share Posted June 23, 2010 Okay. I know what's wrong. Guess the DOM doesn't get updated with pages loaded in iframes. Link to comment Share on other sites More sharing options...
Question
Jebadiah
I am trying to get the <object> tag's innerHTML from firebug using JQuery, but when I run $('object').html(); from Firebug it always returns null.
I am unable to set attributes for the tag too: $('object').attr('abcd', 'efgh');
The same happens with embed tags as well.
Does anyone know why? What are some alternatives to get/set those attributes of object tags?
Any inputs would be useful. Thanks!
Link to comment
Share on other sites
2 answers to this question
Recommended Posts