I am attempting to execute a JavaScript function on each element of an ASP.NET page that is assigned a specific CSS Class. Despite my limited knowledge of JavaScript, I am unable to determine why the code is not functioning properly. The CSS Class is being dynamically added to controls and is also associated with a static control on the page.
My goal is simply to have these controls fade in once the page has finished loading.
Below is the script I am using:
<script type="text/javascript">
$(document).ready(function () {
$('.fadeInLoad').each(function (i, obj) {
$(this).fadeIn();
});
});
</script>
Here is the corresponding CSS Code:
.fadeInLoad
{
color:#0d0d0d;
}
Your assistance in resolving this issue would be greatly appreciated. Thank you.