var sweepssubpath="fitnesschallenge";
var sweepsname="Live's Staff Fitness Challenge Giveaway";
var date18="December 28, 2007";
var datend="March 24, 2008";

thisMLC=_gmlc+'/contests/'+sweepssubpath;
templatedate=new Date();

styles=[
["fieldset","border:1px solid #516C7D; width:400px;"],
["legend, .butter, .overbutter","font:bold 12px arial;"],
["legend","color:#EE7000;"],
[".error","font:bold 16px arial; color:#EE7000;"],
["#MANDY","font-size:11px; padding-top:20px;"],
["#loginbutton, #enterbutton","width:100px;"]
];
document.writeln('<style>');  for (sty in styles){ document.writeln(styles[sty][0]+'{ '+styles[sty][1]+' }'); }  document.writeln('</style>');

rulesURL="http://bventertainment.go.com/tv/buenavista/regisandkelly/contests/"+sweepssubpath+"/rules.html";
thisHeader={ header:"contests/fitnesschallenge/images/header-image.swf" };

function goRules(){ window.location.href=rulesURL; }

function popFinalStats(){
_vinny=window.open("","stats","top=1,left=1,width=705,height=395,statusbar=0,scrollbars=0").document;
_vinny.write('<html><head><title>FINAL STATS FROM Live\'s 2005 Fitness Challenge</title></head><body style="margin:0; padding:0; background:#EDFFE4;">\
<img src="images/finalstats2005.gif" width="705" height="395" border="0" alt="">\
</body></html>');
_vinny.close();
}

function writeLocalNav(_gpnoverride){

_gpnoverride=(_gpnoverride==null)?_gpn:_gpnoverride;

document.write('<div style="background:#85AECD; width:795px; margin:0 auto 0 auto; text-align:left;">');

new threeStateButton({ id:"index", href:"http://bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/index.html", image:_proto+"bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/nav-home-off.gif" },_gpnoverride).write();
new threeStateButton({ id:"progressreports", href:"http://bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/progressreports.html", image:_proto+"bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/nav-progress-off.gif" }).write();
new threeStateButton({ id:"blogs", href:"http://bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/blogs.html", image:_proto+"bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/nav-blogs-off.gif" }).write();
new threeStateButton({ id:"support", href:"https://register.go.com/regisandkelly/sweeps/fitnesschallenge/index", image:_proto+"bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/nav-support-off.gif" },_gpnoverride).write();

document.write('</div>');

}


function writeTravelTriviaTop(){
document.writeln('<div align="center"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/live-fitness-logo.jpg" border="0"></div>');
}

function writeEntryForm(){
document.writeln('<div align="center"><b>Select a Live Staffer to support, fill in the information below<br> and click "Submit" to complete your entry.</b></div>\
<br>\
<table>\
<tr><td>\
<input type="radio" name="value" id="value0" value="Laurie Ciaffaglione" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value0"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-laurie-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Laurie Ciaffaglione</b><br>\
Weight: 118.9<br>\
Goal: To lose 5-10 pounds, and tone her body, focusing on her triceps, butt, love handles and thighs.\
</td></tr>\
<tr><td>\
<input type="radio" name="value" id="value1" value="Delores Spruell Jackson" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value1"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-delores-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Delores Spruell Jackson</b><br>\
Weight: 174.7<br>\
Goal: Wants to improve physical health through exercise and eating healthier. Hopes to lose 20 pounds ... if not more!\
</td></tr>\
<tr><td>\
<input type="radio" name="value" id="value2" value="Cindy MacDonald" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value2"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-cindy-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Cindy MacDonald</b><br>\
Weight:149.3<br>\
Goal: To lower her cholesterol, feel healthy and lose 20 pounds.\
</td></tr>\
<tr><td>\
<input type="radio" name="value" id="value3" value="Marco Puglia" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value3"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-marco-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Marco Puglia</b><br>\
Weight: 216.6<br>\
Goal: To drop down to a slim and fit 175-180 pounds.\
</td></tr>\
<tr><td>\
<input type="radio" name="value" id="value4" value="Mariann Sabol" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value4"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-mariann-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Mariann Sabol</b><br>\
Weight: 127.5<br>\
Goal: "I want to look good in clothes as well as out of them!" Overall toning and tightening of belly, thighs and upper arms.\
</td></tr>\
<tr><td>\
<input type="radio" name="value" id="value5" value="Lori Schulweis" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value5"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-lori-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Lori Schulweis</b><br>\
Weight: 160.1<br>\
Goal: Wants to learn how to eat and exercise to stay thin for the rest of her life. Hoping to lose 30 pounds.\
</td></tr>\
<tr><td>\
<input type="radio" name="value" id="value6" value="Elyssa Shapiro" onclick="gid(\'valueinput\').value=this.value">\
</td><td>\
<label for="value6"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/photo-elyssa-sm.jpg" border="0" class="orangeborder"></label>\
</td><td>\
<b>Elyssa Shapiro</b><br>\
Weight: 119.6<br>\
Goal: Lower her cholesterol down, tone up, and feel more energetic. Tired of being flabby, but doesn\'t want to be too muscular.\
</td></tr>\
</table>\
<br><br>');

for (i=0; i<=6; i++){
gid('value'+i).checked=false;
}

}

entryCopy="<b>Register here to support the staff member whose weight loss and fitness goals and challenges best correspond to yours.</b> The first 500 people to register and support the staff member who ultimately loses the biggest percentage of body weight will receive a pair of ASICS GEL running shoes and a copy of the book, \"15 Minutes to Your Best Self.\" ALL entrants will receive access to a free 1 month Diet Club trial and the self.com Fitness Assessment quiz!\
<br><br>\
Read their blogs to hear how things are going, and check out the fitness and nutrition tips and tools designed for each staff member based on their goals and challenges, but PLEASE NOTE: If you have similar goals to this participant and are interested in utilizing the tips outlined here, you should consult with your doctor before beginning this, or any, weight loss or fitness program.<br><br>";

mandatory='<br>NO PURCHASE NECESSARY. Void where prohibited. Open to legal residents of the fifty states of the U.S., D.C. and Canada (excluding Province of Quebec). <a href="javascript:goRules()">CLICK HERE for the Official Terms of Viewer Giveaway.</a> Prize restrictions apply. ';

loginbutton='<input type="submit" value="LOG-IN >>" class="butter" id="loginbutton" onmouseover="this.className=\'overbutter\'" onmouseout="this.className=\'butter\'">';
enterbutton='<input type="submit" value="SUBMIT" class="butter" id="enterbutton" onmouseover="this.className=\'overbutter\'" onmouseout="this.className=\'butter\'"><br><br><br>\
<div align="center"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/15mincover.jpg" border="0" align="absmiddle" style="margin-right:15px;"> <img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/shoes.jpg" border="0" align="absmiddle"></div>';

function writeText(_text){
switch(_text){
case 'LOGGED_IN':
document.writeln(entryCopy);
writeEntryForm();
break;
case 'NOT_LOGGED_IN':
document.writeln(entryCopy);
document.writeln('<div align="center"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/15mincover.jpg" border="0" align="absmiddle" style="margin-right:15px;"> <img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/shoes.jpg" border="0" align="absmiddle"></div><br>\
You need to be a registered <b>"Live with Regis and Kelly"</b> user to participate.');
break;
case 'REQUIRED_FIELDS':
break;
case 'SUCCESS':
document.writeln('<div align="left"><div align="center" style="font:bold 16px arial;">Thanks for registering to support a staff member<br> participating in Live\'s Staff Fitness Challenge!</div><br>Now that you\'ve voted for your favorite LIVE staffer, make sure you both stay motivated:<br><br>\
<li>Read the <a href="http://blogs.liveregisandkelly.com/behind_the_scenes/">staffer\'s blog</a> to follow her (or his) progress.<br><br>\
<li>Check out <a href="javascript:GOurl(\'http://www.self.com/health/blogs/loseit\')">their profiles</a> to learn more about them.<br><br>\
<li>To kick-start your own challenge, check out SELF\'s free online <a href="javascript:GOurl(\'http://www.self.com/fitness/articles/2007/02/fit_quiz_opener\')">fitness assessment quiz</a>.<br><br>\
<li>To keep you going, get a free one-month membership to the <a href="javascript:GOurl(\'http://www.selfdietclub.com/dt/pl/self/30daytrial.asp\')">SELF Diet Club</a>, with access to a food log, meal planner and more.<br><br>\
In just 12 weeks, you can both slim down and get in better-than-ever shape!\
<br><br>\
<div align="center"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/self-logo-large.gif" border="0"></div></div>\
<br><br>\
<a href="http://bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/">Click here</a> for more information about Live\'s Staff Fitness Challenge\
<br><br>'+returntohomepage+'\
<div align="center"><img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/15mincover.jpg" border="0" align="absmiddle" style="margin-right:15px;"> <img src="'+_proto+'bventertainment.go.com/tv/buenavista/regisandkelly/contests/fitnesschallenge/images/shoes.jpg" border="0" align="absmiddle"></div>');
break;
case 'FAMILY_OF_SITES':
document.writeln('<span style="font-size:11px;">(<b>**Note:</b> If you are already registered at LiveRegisandKelly.com, ABC.com, ABCNEWS.com, ESPN.com, FamilyFun.com, Movies.com, or Disney Online, you may use your existing Member ID and Password. You do NOT have to re-register... just login with your Member ID and password.)</span><br>');
break;
case 'CLICK_HERE_TO_REGISTER':
document.writeln('<b>Not yet registered? <a href="../../index?appRedirect=sweeps/'+sweepssubpath+'/index">CLICK HERE</a></b>');
default:break;
}
}


function writeErrorMsg(irma){
document.writeln('<div align="center">');
switch(irma){
case 'ALREADY_ENTERED_IN_TIMEUNIT':
document.writeln('<div class="error">Sorry but you\'ve already signed up.</div><br><br></span>'); break;
case 'EARLY':
document.writeln('<div class="error">SORRY!</div><br><b>'+sweepsname+'</b> has not yet started.  Please return <b>'+date18+'</b> to enter for your chance to win.'); break;
case 'OVER':
document.writeln('<div class="error">SORRY!</div><br>Online entry in <b>'+sweepsname+'</b> is now closed.'); break;
case 'INVALID_AGE':
document.writeln('<div class="error">SORRY!</div><br>Sorry but you must be 13 or older to participate in this promotion.<br><br>\
Please ask your parent to register as a member of<br> Live with Regis and Kelly to participate in this giveaway.'); break;
case 'QUEBEC':
document.writeln('<div class="error">SORRY!</div><br><b>LIVE\'s '+sweepsname+'</b> is not open to residents of Quebec.<br><br><a href="../../update?appRedirect=sweeps/'+sweepssubpath+'/index">Verify/Update address information</a>'); break;
default:break;
}
document.writeln('<br><br>'+returntohomepage+'</div>');
}

returntohomepage='<a href="http://liveregisandkelly.com/">Return to the <b>"Live with Regis and Kelly"</b> homepage</a><br><br><br>';



function checkStuff(me){

hasChecked=false;
for (i=0; i<=6; i++){ if (gid('value'+i).checked){ hasChecked=true; break; }}
if (!hasChecked){
alert('Please select a participant.'); return false;
}

eee=[
["line1", "Please confirm your address."],
["city", "Please confirm your city."],
["stateProvince", "Please confirm your state."],
["postalCode", "Please confirm your zip code."],
["emailAddress", "Please type in your e-mail address."]
];
for (cc=0; cc<eee.length; cc++){
elle=me.elements[eee[cc][0]];
if (((elle.type=="text" || elle.type=="textarea" || elle.type=="file") && elle.value=='') || (elle.type=="select-one" && elle.selectedIndex==0)){
alert(eee[cc][1]); elle.focus(); return false;
}}

//stripped=me.value.value.replace(/[\(\)\.\-\ ]/g,'');
//if (!(!isNaN(parseInt(stripped)) && stripped.length==10)){ alert('Please check your phone numbers for errors. Suggested format: XXX-XXX-XXXX'); me.value.focus(); return false; }

return true;
}

function writeTopAd(){
document.writeln('<IFRAME SRC="https://3ps.go.com/DynamicAd?srvc=bvtv&itype=Banner&url=/regisandkelly/contests/'+sweepssubpath+'/&secure=true" border="0" width="728" height="90" SCROLLING="NO" FRAMEBORDER="0" MARGINHEIGHT="0" MARGINWIDTH="0"></IFRAME>');
}
function writePosterAd(){
document.writeln('<IFRAME SRC="https://3ps.go.com/DynamicAd?srvc=bvtv&itype=Skyscraper&url=/regisandkelly/contests/'+sweepssubpath+'/&secure=true" border="0" width="160" height="600" SCROLLING="NO" FRAMEBORDER="0" MARGINHEIGHT="0" MARGINWIDTH="0"></IFRAME><br><br>');
}