function specials() {
var content = '';
content += '<TABLE WIDTH="135" BORDER="0" CELLSPACING="0" CELLPADDING="2" BGCOLOR="#0066CC">';
content += '';
content += '<TR>';
content += '<TD CLASS="Nav2Header" WIDTH="5%">&nbsp;</TD><TD CLASS="Nav2Header" WIDTH="95%" COLSPAN="2">Special Reports</TD>';
content += '</TR>';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '<TR><TD CLASS="Nav2SectionChevron" WIDTH="10%" COLSPAN="2" ALIGN="RIGHT" VALIGN="TOP">&#0155;</TD><TD CLASS="Nav2Section" WIDTH="90%"><A HREF="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=974089105216" CLASS="Nav2SectionLink">Federal Election</A></TD></TR>';
content += '<TR><TD CLASS="Nav2SectionChevron" WIDTH="10%" COLSPAN="2" ALIGN="RIGHT" VALIGN="TOP">&#0155;</TD><TD CLASS="Nav2Section" WIDTH="90%"><A HREF="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1045739058633" CLASS="Nav2SectionLink">Conflict in Iraq</A></TD></TR>';
content += '<TR><TD CLASS="Nav2SectionChevron" WIDTH="10%" COLSPAN="2" ALIGN="RIGHT" VALIGN="TOP">&#0155;</TD><TD CLASS="Nav2Section" WIDTH="90%"><A HREF="http://www.thestar.com/interest" CLASS="Nav2SectionLink">Matter of Interest</A></TD></TR>';
content += '<TR><TD CLASS="Nav2SectionChevron" WIDTH="10%" COLSPAN="2" ALIGN="RIGHT" VALIGN="TOP">&#0155;</TD><TD CLASS="Nav2Section" WIDTH="90%"><A HREF="http://www.thestar.com/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1044529386722" CLASS="Nav2SectionLink">Euro 2004</A></TD></TR>';
content += '<TR><TD CLASS="Nav2SectionChevron" WIDTH="10%" COLSPAN="2" ALIGN="RIGHT" VALIGN="TOP">&#0155;</TD><TD CLASS="Nav2Section" WIDTH="90%"><A HREF="http://www.thestar.com/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1044529392193" CLASS="Nav2SectionLink">Wimbledon</A></TD></TR>';
content += '<TR><TD CLASS="Nav2SectionChevron" WIDTH="10%" COLSPAN="2" ALIGN="RIGHT" VALIGN="TOP">&#0155;</TD><TD CLASS="Nav2Section" WIDTH="90%"><A HREF="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1034676683947" CLASS="Nav2SectionLink">[More Specials]</A></TD></TR>';
content += '';
content += '</TABLE>';
content += '';
content += '';
content += '';
content += '';
content += '';
content += '';
document.write(content);
}

function feature() {
var content = '';
content += '<TABLE width="100%" border="0" cellspacing="0" cellpadding="0" bgcolor="#CCCCCC"><tr><FORM><td colspan="5" class="expull1"><SELECT name="ExtraSections" class="expull1" onChange="MM_jumpMenu(\'parent\',this,0)"> <OPTION VALUE="#">Feature Sections';
content += '<OPTION VALUE="#">----------';
content += '';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=971794782442">@Biz</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1011789353817">Books</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1010666657320">Condos</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=973280119494">Fashion</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867496431">Food</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867505381">Health</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867497496">Homes</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867505075">I.D.</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1045739000572">Metropolis</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=976600361453">Movies</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867506610">Travel</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=978552666364">What\'s On</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867497088">Wheels</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1038394944805">World [Sunday]</OPTION>';
content += '';
content += '';
content += '<OPTION VALUE="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=1021543364560">Your Home</OPTION></SELECT></td></FORM></tr><TR><td colspan="5" class="sat1">&nbsp;&nbsp;Today\'s Features</td></TR><TR>';
content += '';
content += '';
content += '<TD width="14"> <DIV align="right" class="satbull">&gt;&nbsp;</DIV> </TD> <TD class="sat"><a href="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=968867505075">I.D.</a></TD></TR><TR></TR></TABLE>';
document.write(content);
}

function weather() {
var content = '';
content += '<table width="122" border="0" cellspacing="0" cellpadding="0">';
content += '<tr> ';
content += '<td class="weather1">Partly Sunny with Thunderstorms</td>';
content += '<td width="3">&nbsp;</td>';
content += '<td rowspan="3"><img src="/images/thestar/weather/icons/17.GIF" width="40" height="40"></td>';
content += '</tr>';
content += '<tr> ';
content += '<td class="weather1">H 24 / L 12</td>';
content += '<td width="3">&nbsp;</td>';
content += '</tr>';
content += '<tr> ';
content += '<td class="weather2">';
content += '<div align="left">';
content += '<NOBR><a href="/NASApp/cs/ContentServer?pagename=thestar/Render&c=Page&cid=971188561551">4 Day Forecast</a></NOBR></div>';
content += '</td>';
content += '<td width="3">&nbsp;</td>';
content += '</tr>';
content += '</table>';
content += '';
content += '';
content += '';
content += '';
content += '';
document.write(content);
}




function checkforblanks(){
  for (var i = 0; i < arguments.length; i += 2){
    if (!arguments[i])	{
	alert("The search field is empty. Please enter text to search Thestar.com.");
	return false;
    }
  }
  return true;
}

function visit( elem ) { 
    i = 0;
    while (i < elem.options.length) {
        if (elem.options[i].selected) {
            newURL = elem.options[i].value;
            break;
        }
        i++;
    }
  if (newURL != "") {
    document.location.href=newURL;
  } else {
        return 0;
  }
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}

function validate(theform) {
  var isFull = checkforblanks(theform.searchstring.value, "Search String");
  if (!isFull)
    {return false;}
}		

function gallery_open( sitename, galleryid, h, w ) {
        var GalleryWindow;
        var pagename = sitename + '/Render';
        if (h == null) {
            h = 500;
        }
        if (w == null) {
            w = 488;
        }
        pagename='thestar/Render';
        var url = '/NASApp/cs/ContentServer?pagename='+pagename+'&c=Gallery&cid=' + galleryid;
        GalleryWindow = window.open( url, 'gallery_window', 'height=' + h + ',width=' + w + ',screenX=10,screenY=10,top=10,left=100,resizable=yes,scrollbars=yes' );
        if (GalleryWindow.opener == null) {
                GalleryWindow.opener = self;
        }

        GalleryWindow.focus();

}

function goTo( url ){
        document.location= url;
        return 1;
}

function getCookie(name){
var cname = name + "=";
var dc = document.cookie;
if(dc.length >0){
   begin = dc.indexOf(cname);
   if(begin != -1 ) {
      begin += cname.length;
      end = dc.indexOf(";", begin);
      if (end == -1) end = dc.length;
        return unescape(dc.substring(begin,end));
      }
   }
return null;
}

function setLongCookie(name, value) {
 var today=new Date();
 var expiry = new Date(today.getTime() + 366*24*3600*1000);
  if(value !=null && value != "")
   document.cookie=name + "=" + escape(value) + "; expires=" + expiry.toGMTString()+"; path=/";
}

function getDomain(){
        url=document.location+"";
        if(url.indexOf("://")==-1){return "-";}
        rest=url.substring(url.indexOf("://")+3);
        domain=rest.substring(0,rest.indexOf("/"));
        return domain;
}

if(getCookie("gx_session_id_")){
        if(!getCookie("starAccess")){
                setLongCookie("starAccess", "Star-"+getCookie("gx_session_id_")+"||"+getDomain());
        }
        else{
                oldCookie=getCookie("starAccess");
                if(oldCookie.indexOf("||")==-1){ thisCookie=oldCookie+"||"+getDomain();}
                else{thisCookie=oldCookie;}
                setLongCookie("starAccess", thisCookie);
        }
}

  IE5 = ((document.all)&&(navigator.appVersion.indexOf("MSIE 5.")!=-1)) ? true : false;
  IE6 = ((document.all)&&(navigator.appVersion.indexOf("MSIE 6.")!=-1)) ? true : false;
  IE5plus = IE5 || IE6;

  if(IE5plus) {
    window.onbeforeprint = trackPrint;

    function trackPrint() {
      var printimg = new Image();
      printimg.src="http://www3.thestar.com/print/page_printed.gif";
    }
  }
