Thursday, January 5, 2012

21st Century Jobs

';

jQuery("#ssFilmstripBody").append(h);

featureList.push(f);
return true;
}

function ssResolution(nextURL) {
pageObj.nextURL = nextURL;
return true;
}

function ssSwapContent() {

// we always want the title
jQuery("#ssPageTitle").html(pageObj.title);

if (pageObj.resolutionMode) {
// BUILD OUT THE RESOLUTION STATE
var headline = jQuery("#ssPageTitle").text();
jQuery("#ssPageTitle").empty();
jQuery("#ssPhotoImgHolder").remove();
jQuery("#ssPhotoAlt").remove();
var replayImage = 'http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/Global/ssReplaySlideshow.gif';
jQuery("").attr("id", "ssReplaySlideshow").attr("src", replayImage).appendTo("#ssPageTitle"); jQuery("#ssPageTitle").append(headline).css({"font-size": "12px","font-weight":"bold"}); jQuery("#ssPhotoNumber").html(pageObj.slide + '?of?'); jQuery("#ssPhotoCount").html(pageObj.DisplayTotal); var cssObj = { 'border-top': '0px solid #fff', 'margin-top': '0px' } jQuery("#CNBCFilmstrip2").css(cssObj); var deckContentText = jQuery('.cnbc_sbhdln:first').text(); var deckContent = ''; if (deckContentText.length >= 1){ deckContent = jQuery('.cnbc_sbhdln:first').html(); } else { deckContent = ''; } jQuery('#ssPhotoCaption').addClass("ssDeckLinks") .append('

More related to:

') .append('

' + headline + '

') .append(deckContent); ssShowTextCheck(); } else { // CREATE THE IMAGE var imageAlign = "left"; // jQuery("#ssPhotoImg").css("width", imageDetails.w + "px"); if (imageObj.Width ") .attr("id", "ssImage") .attr("src", imageObj.MediaRoot2 + '/i' + imageObj.FileName) .attr("width", imageObj.Width) .attr("height", imageObj.Height) .attr("align",imageAlign) .attr("border","0") .appendTo("#ssPhotoImg"); } else { var fileNameExtPos = imageObj.FileName.lastIndexOf('.'); var fileNameExt = imageObj.FileName.substring(fileNameExtPos); var fileNameBase = imageObj.FileName.substring(0, fileNameExtPos); var fileName = fileNameBase + '.aim640' + fileNameExt; jQuery("") .attr("id", "ssImage") .attr("src", imageObj.MediaRoot2 + '/j' + fileName) .attr("width", imageObj.Width) .attr("height", imageObj.Height) .attr("align",imageAlign) .attr("border","0") .appendTo("#ssPhotoImg"); } jQuery("#ssPhotoNumber").html(pageObj.slide + '?of?'); jQuery("#ssPhotoCount").html(pageObj.DisplayTotal); if (imageObj.Credits != '') { jQuery("#ssPhotoCredit").html(imageObj.Credits); } if (imageObj.Caption != '') { jQuery("#ssPhotoCaption").html(imageObj.Caption); } if (imageObj.Alt != '') { jQuery("#ssPhotoAlt").html(imageObj.Alt); } } // ADD THE MAIN NEXT AND BACK BUTTONS // THIS IS JUST THE IMAGES. WE WILL APPLY THE EVENTS LATER if (pageObj.slide == 1) { // first slide // blank jQuery("").attr("src", "http://media.cnbc.com/i/CNBC/CNBC_Images/blank.gif") .attr("width", "44") .attr("height", "44") .attr("border", "0") .appendTo("#ssPhotoLinks"); // next jQuery("").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOffNext.gif") .attr("width", "44") .attr("height", "44") .attr("border", "0") .attr("id", "ssNextBtn") .appendTo("#ssPhotoLinks"); } else { // all the rest // BACK jQuery("").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOffBack.gif") .attr("width", "44") .attr("height", "44") .attr("border", "0") .attr("id", "ssBackBtn").appendTo("#ssPhotoLinks"); // NEXT jQuery("").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOffNext.gif") .attr("width", "44") .attr("height", "44") .attr("border", "0") .attr("id", "ssNextBtn").appendTo("#ssPhotoLinks"); } jQuery('#cnbc_textbody').replaceWith(jQuery('#ssWide').html()); jQuery('#ss_right_rail').replaceWith(jQuery('#ssThin').html()); ssShowTextCheck(); } // NEXT AND BACK function ssNext() { if (pageObj.resolutionMode) { if (featureList.length >=1){ var path = document.location.pathname; var pathArray = path.split("/"); var wbId = ''; for (i = 0; i 1) { document.location = '?slide=' + (pageObj.s - 1); } } // SLIDE CAPTION function ssShowTextCheck() { if (jQuery("#ssPhotoCaptionScroll").height() ").attr("id", "ssShowTextBtn").attr("src", 'http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/Global/ssReadMoreShow_1.gif') .attr("width", "75") .attr("height", "16") .attr("border", "0") .appendTo("#ssReadMore"); } } // JQUERY DOC READY jQuery(document).ready(function() { // output ************************************************************* jQuery('#cnbc_textbody').empty(); // bindings jQuery(document).bind('NEXT_OVER', function(e) { jQuery("#ssNextBtn").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOnNext.gif"); window.status = 'Next Slide'; }); jQuery(document).bind('NEXT_OUT', function(e) { jQuery("#ssNextBtn").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOffNext.gif"); window.status = ''; }); jQuery(document).bind('NEXT_CLICK', function(e) { ssNext(); }); jQuery(document).bind('BACK_OVER', function(e) { jQuery("#ssBackBtn").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOnBack.gif"); window.status = 'Previous Slide'; }); jQuery(document).bind('BACK_OUT', function(e) { jQuery("#ssBackBtn").attr("src", "http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/ss_btnOffBack.gif"); window.status = ''; }); jQuery(document).bind('BACK_CLICK', function(e) { ssBack(); }); // SHOW HIDE TEXT jQuery(document).bind('SHOW_TEXT', function(e) { var captionHeight = jQuery("#ssPhotoCaption").height(); if (jQuery("#ssPhotoCaptionScroll").height() >= captionHeight) { // we need to bring it down jQuery("#ssPhotoCaptionScroll").animate({ height: 142 }, 500); jQuery("#ssShowTextBtn").attr("src", 'http://media.cnbc.com/i/CNBC/Components/Slideshow_V2/Global/ssReadMoreShow_1.gif'); } else if (jQuery("#ssPhotoCaptionScroll").height()

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.