/****** COMPONENT ******/ if( typeof( $ ) == 'undefined' ) { alert('WARNING - JQuery core library missing!'); } else { $(document).ready(function(){ // Highlighting a menu tab based on current page $(".headerMenuTab").each( function(){ if( pageName == $(this).attr( 'tabName' ) ) { $('img', this).attr( "src", d_HTTP_SITE_MEDIA + '/images/cms/menu_tab_' + $(this).attr( 'tabName' ) + '_on.gif' ); } else { $('img', this).attr( "src", d_HTTP_SITE_MEDIA + '/images/cms/menu_tab_' + $(this).attr( 'tabName' ) + '_off.gif' ); } }); // Hovering over a menu tab $(".headerMenuTab").hover( function() { if( pageName != $(this).attr( 'tabName' ) ) { $('img', this).attr( "src", d_HTTP_SITE_MEDIA + '/images/cms/menu_tab_' + $(this).attr( 'tabName' ) + '_on.gif' ); } }, function() { if( pageName != $(this).attr( 'tabName' ) ) { $('img', this).attr( "src", d_HTTP_SITE_MEDIA + '/images/cms/menu_tab_' + $(this).attr( 'tabName' ) + '_off.gif' ); } } ); $('#site_header_search_go').css('cursor', 'pointer'); $('#site_header_search_go').click(function(){ //$.jqURL.loc( 'http://' + d_SITE_DOMAIN + '/search?ser=' + $("#site_header_search").val() + '&q=' + $("#site_header_search_keys").val() ); window.open( 'http://' + d_SITE_DOMAIN + '/search?ser=' + $("#site_header_search").val() + '&q=' + $("#site_header_search_keys").val(), '_self' ); }); $('#headerTabLogin').click(function(){ $('#site_header_login_panel').fadeIn(300); // setting default login text var defaultHeadEnailText = "Email address..."; if( $("#loginemail").val() == '' ){ $("#loginemail").val( defaultHeadEnailText ); } $("#loginemail").focus(function(){ if( $(this).val() == defaultHeadEnailText ) { $(this).val(""); } }).blur(function(){ if( $(this).val() == "" ) { $(this).val( defaultHeadEnailText ); } }); return false; }); $('.siteHeaderLoginButton').click(function(){ //$('#welcomeLoginButtContainer').hide(); //$('#welcomeLoginAjaxContainer').fadeIn(200); rememberMe = 'yes'; $.ajax({ url: WEB_SERVICE+"/jscript/login.ws.php", type: "POST", cache: false, data: "email="+encodeURIComponent( $('#loginemail').val() )+"&password="+encodeURIComponent( $('#loginpass').val() )+"&remember="+rememberMe+"&redirect="+encodeURIComponent( $('#redirectTo').val() )+"&apikey="+SERVICES_API_KEY+"&authToken="+AUTH_TOKEN+"&reqType=sessionLogin&reqCall=doLogin", success: function( returnData, textStatus ) { // This stops browsers like IE from caching var currentTime = new Date(); $.jqURL.loc( returnData + '?lgToken=' + currentTime.getTime() ); }, error: function( requestOb ) { //$('#welcomeLoginAjaxContainer').hide(); //$('#welcomeLoginButtContainer').fadeIn(200); var msgArr = $("msg", requestOb.responseXML).text().split("::"); $.prompt(msgArr[1], { prefix:'impromptu', buttons: { OK: 'ok' } }); } }); return false; }); }); } /****** COMPONENT ******/ if( typeof( $ ) == 'undefined' ) { alert('WARNING - JQuery core library missing!'); } else { $(document).ready(function(){ }); } /****** COMPONENT ******/ if( typeof( $ ) == 'undefined' ) { alert('WARNING - JQuery core library missing!'); } else { $(document).ready(function(){ $("#media_slider").easySlider({ prevId: 'prevBtn', prevText: '', nextId: 'nextBtn', nextText: '', pause: 5000, auto: true, continuous: true }); }); } /****** COMPONENT ******/ if( typeof( $ ) == 'undefined' ) { alert('WARNING - JQuery core library missing!'); } else { $(document).ready(function(){ $('#recentVideosContainer').jScrollPane({showArrows:true, scrollbarWidth: 10}); }); }