﻿// JScript File
function DivSlider() {
	$('#fp-aztable-c > table tbody tr td div').filter('.fp-details-c').hide();
    $('#fp-aztable-c > table tbody tr td div').filter('.fp-expand-contract').click(function() {
  		//var $nextDiv = $(this).parent().parent().next('tr td.fp-details-w div.fp-details-c');
  		//var $nextDiv = $(this).parent().parent().next().children().children().filter('tr td.fp-details-w div.fp-details-c');
  	    var $nextDiv = $(this).parent().parent().next().children().children().children();	
  		$nextDiv.slideToggle('fast');
  		var $image=$(this).children('img');
  		$image.attr('src',function() {
			this.src=(this.src.indexOf("az_contract.gif") != -1) ? "images/az_expand.gif" : "images/az_contract.gif";
		});
	});
}

var IECheck;
function IEContentLoaded(w,f){
    // document has loaded (IE method 2) using behavior
    var load=false,d=w.document,s=d.createStyleSheet().owningElement;
    s.styleSheet.cssText='body{behavior:expression(IECheck(this));}';
    var fire=function(e){if(!load)
{load=true;f.call(d,e);setTimeout(function()
{s.parentNode.removeChild(s);},10);}};
    IECheck=function(n)
{try{d.documentElement.doScroll('left');n.runtimeStyle.behavior='none';}catch(e)
{return;}fire(null);};
}

if($.browser.msie) {
  IEContentLoaded(window,function() {
   DivSlider();
  })
} else {
  $(document).ready(function() {
    DivSlider();
  })
}