If you use jQuery, the following returns true if the object is visible:
$(object).is(':visible');
If not, you can try the following:
if (object.style['display'] != 'none')
But this will only work if display:noneexplicitly set for this object.
source
share