$(function(){
    try {
        if (dlp.currentPage == "one") {
            //MOID REWRITE
            var MO  = marketingOfferList;
            var HL  = $('div#headline h1').text();
            var SHL = $('div#headline h2').text();
            var regEx = new RegExp();
            var token = "";

            $(MO).each(function(index, moidValue){
                token = 'MO\\['+index+'\\]';
                regEx.compile(token);
                HL = HL.replace(regEx, '<span class="MO-'+index+'">'+MO[index]+'</span>');
                SHL = SHL.replace(regEx, '<span class="MO-'+index+'">'+MO[index]+'</span>');
            });

            //CLEANUP UNUSED TOKENS  
            token = '(MO\\[\\d+\\])';
            regEx.compile(token, 'g');
            HL = HL.replace(regEx, '');
            SHL = SHL.replace(regEx, '');

            $('div#headline h1').html(HL);
            $('div#headline h2').html(SHL);
            
            
            //FINANCIAL AID TEXT FROM CONTENT ELEMENT
            
			//Content element, CUSA_CALLOUT_TEXT value 
			var CO  = callOutList;
			var statePropertyCodeText = statePropertyDesc;
			
			//Adding first 2 elements of the CUSA_CALLOUT_TEXT array, this formula can be changed based on the array values
			var callOutValue = '<span class="CO-0">'+CO[0]+'</span>'
							  + ' <span class="CO-1">'+CO[1]+'</span>';
							  
			//Adding  state property code value if present, this formula can be changed based on the array values			  
			if(statePropertyCodeText!=null && statePropertyCodeText != ''){
			callOutValue = callOutValue + ' <span class="statePropertyAppend"> in </span>' 
										  + ' <span class="statePropertyDesc">' + statePropertyCodeText + '</span>';			
			}
			
			//Adding 3rd element of the CUSA_CALLOUT_TEXT array, this formula can be changed based on the array values
			callOutValue = callOutValue + '<span class="CO-2">'+CO[2]+'</span>';
			$('div#financialAidRow a').html(callOutValue);	
					
    		//END FINANCIAL AID TEXT 
    		

            //DISCLOSURE INSERT
            //$('div#footer').after('<div class="disclosure">'+disclosureText+'</div>');
        }
    } catch (exception){}
    dlp.action.render(dlp.currentPage, dlp);
});

//Page 3
//=========================
//Headline
dlp.page.three.headlineText.text = ['Last Step: Get Your Free Information!'];
dlp.page.three.headlineText.style.firefox =     {fontSize:'23px', fontWeight:'bold', position:'relative', left:'7px', top:'0px', zIndex:'901'};
dlp.page.three.headlineText.style.ie6 =         {fontSize:'23px', fontWeight:'bold', position:'relative', left:'7px', top:'0px', zIndex:'901'};
dlp.page.three.headlineText.style.ie7 =         {fontSize:'23px', fontWeight:'bold', position:'relative', left:'7px', top:'0px', zIndex:'901'};

//Submit Button
dlp.page.three.submitButton.style.firefox =     {backgroundImage:'url(/contentelements/42638/images/buttons/clickHereToGetYourFreeInfo.jpg)', height:'39px', left:'116px', top:'9px', width:'396px'};
dlp.page.three.submitButton.style.ie6 =         {backgroundImage:'url(/contentelements/42638/images/buttons/clickHereToGetYourFreeInfo.jpg)', height:'39px', left:'-85px', top:'9px', width:'396px'};
dlp.page.three.submitButton.style.ie7 =         {backgroundImage:'url(/contentelements/42638/images/buttons/clickHereToGetYourFreeInfo.jpg)', height:'39px', left:'116px', top:'9px', width:'396px'};



//IGNORE THE FOLLOWING:
//Process Page
$(function(){
    dlp.action.render(dlp.currentPage, dlp);
});