I am facing an issue with displaying an element that is defined as display:none in CSS. I tried to use the .show() function in jQuery, but it's not working as expected. Here's the code snippet:
CSS
.element {
position: absolute;
display: none;
left: 0;
top: 0;
}
HTML
<div class="element">Some content here</div>
<div class="element">Some content here</div>
jQuery
var c = $('.element');
c.each(function () {
c.css({
'left': dleft + 'px'
});
c.css({
'top': dtop + 'px'
});
c.setTimeout(function () {
c.show(1000);
}, sduration);
I have checked all variables and even set default values for them, yet the element remains hidden after the timeout period.