Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to remove an inline style of display:none using jquery?

I'm using jquery tabs on my site. I've just installed a new jquery plugin (smooth zoom) for a map I'm using, but it wasn't dipalying . I checked firebug and it's creating an an inline style of display: none.

I've tried using the following to remove the display style, but it's not worked

$(document).ready(function(){
    $("#tabs-4").css('display', '');
});

Is there any way I can completely remove all inline styles from this element using jquery?

like image 698
user2114762 Avatar asked Dec 21 '22 09:12

user2114762


1 Answers

try with .removeAttr():

$(document).ready(function(){
    $("#tabs-4").removeAttr('style');
});

and if it doesn't do on doc ready then you can try with window load:

$(window).load(function(){
   $("#tabs-4").removeAttr('style');
});
like image 150
Jai Avatar answered Dec 26 '22 20:12

Jai