I am building a toolbar that is going to be included into a page. the div it is going to be included in will default to display:none. Is there a way i can p
I had this same problem and created a jQuery plugin to solve it for our site.
https://github.com/shaunbowe/jquery.visibilityChanged
Here is how you would use it based on your example:
$('#contentDiv').visibilityChanged(function(element, visible) { alert("do something"); });