



// Create arrays of articles
syndicate.article_title = new Array;
syndicate.article_url = new Array;
syndicate.article_date = new Array;
syndicate.article_summary = new Array;
syndicate.article_content = new Array;

// This section of the script is published by the software
syndicate.index = 0;
  syndicate.article_title[ syndicate.index ] = 'Warriors re-sign C Biedrins to 6-year, $62M deal';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Warriors_re-sign_C_Biedrins_to_6-year_62M_deal.htm';
  syndicate.article_date[ syndicate.index ] = 'Jul 28, 2008 - 6:13:19 PM';
  syndicate.article_summary[ syndicate.index ] = 'The Golden State Warriors re-signed center Andris Biedrins to a six-year contract worth more than $62 million Monday, retaining another restricted free agent and possibly capping a tumultuous month for the club.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Warriors re-sign Ellis to multiyear deal';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Warriors_re-sign_Ellis_to_multiyear_deal.htm';
  syndicate.article_date[ syndicate.index ] = 'Jul 25, 2008 - 2:29:52 AM';
  syndicate.article_summary[ syndicate.index ] = 'The Golden State Warriors made sure they would have Monta Ellis in their backcourt at least for the near future, re-signing the explosive guard to a multiyear contract Thursday.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Warriors exercise option on Don Nelson';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Warriors_exercise_option_on_Don_Nelson.htm';
  syndicate.article_date[ syndicate.index ] = 'Mar 11, 2008 - 5:24:07 PM';
  syndicate.article_summary[ syndicate.index ] = 'The Golden State Warriors exercised the option Tuesday to keep coach Don Nelson under contract for the 2008-09 season.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Chris Webber set to return to Warriors';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Chris_Webber_set_to_return_to_Warriors.htm';
  syndicate.article_date[ syndicate.index ] = 'Jan 28, 2008 - 11:30:16 PM';
  syndicate.article_summary[ syndicate.index ] = 'More than 13 years after Chris Webber demanded to leave the Golden State Warriors, the free-agent forward is all set to return.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Warriors waive disgruntled G Sarunas Jasikevicius';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Warriors_waive_disgruntled_G_Sarunas_Jasikevicius.htm';
  syndicate.article_date[ syndicate.index ] = 'Sep 20, 2007 - 6:38:01 PM';
  syndicate.article_summary[ syndicate.index ] = 'The Golden State Warriors waived Sarunas Jasikevicius on Thursday, agreeing to a contract buyout with the disgruntled guard.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Don Nelson will return to coach Warriors';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Don_Nelson_will_return_to_coach_Warriors.htm';
  syndicate.article_date[ syndicate.index ] = 'Sep 16, 2007 - 9:33:09 PM';
  syndicate.article_summary[ syndicate.index ] = 'Don Nelson and the Golden State Warriors agreed to a new contract Sunday, keeping Nelson as the team\'s coach again this season.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Warriors agree to contract buyout with center Adonal Foyle';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Golden_State_Warriors_84/Warriors_agree_to_contract_buyout_with_center_Adonal_Foyle.htm';
  syndicate.article_date[ syndicate.index ] = 'Aug 13, 2007 - 8:38:15 PM';
  syndicate.article_summary[ syndicate.index ] = 'The Golden State Warriors have reached agreement on a buyout with center Adonal Foyle, parting ways Monday with the 10-year veteran and the team\'s longest-tenured player.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Jazz beat Warriors, take 3-1 series lead';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Utah_Jazz_83/Jazz_beat_Warriors_take_3-1_series_lead.htm';
  syndicate.article_date[ syndicate.index ] = 'May 14, 2007 - 7:48:14 AM';
  syndicate.article_summary[ syndicate.index ] = 'Carlos Boozer had 34 points and 12 rebounds and the Utah Jazz handed the eighth-seeded Golden State Warriors their first home loss of the postseason, 115-101 on Sunday to put Utah up 3-1 in their second-round playoff series.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Fisher fine-tunes Jazz in overtime win';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Utah_Jazz_83/Fisher_fine-tunes_Jazz_in_overtime_win.htm';
  syndicate.article_date[ syndicate.index ] = 'May 10, 2007 - 7:44:18 AM';
  syndicate.article_summary[ syndicate.index ] = 'Derek Fisher capped a dramatic night by scoring all five of his points in overtime in Utah\'s 127-117 victory over Golden State on Wednesday night - a game Fisher nearly missed while returning from New York, where his baby daughter underwent cancer surgery.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Boozer\'s basket lifts Jazz in Game 1';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Utah_Jazz_83/Boozer_s_basket_lifts_Jazz_in_Game_1.htm';
  syndicate.article_date[ syndicate.index ] = 'May 8, 2007 - 7:30:13 AM';
  syndicate.article_summary[ syndicate.index ] = 'Carlos Boozer turned his 20th rebound into the tiebreaking basket with 17 seconds left, and Utah beat the Golden State Warriors 116-112 on Monday night in the opener of the Western Conference semifinals.';
  syndicate.index++;




// Set defaults for arguments if user hasn't set them
if (syndicate.title_fontface == null)    { syndicate.title_fontface = 'Geneva, Arial, sans-serif'; }
if (syndicate.title_fontsize == null)    { syndicate.title_fontsize = '2'; }
if (syndicate.title_fontcolor == null)   { syndicate.title_fontcolor = '#003366'; }
if (syndicate.title_fontbold == null)    { syndicate.title_fontbold = true; }
if (syndicate.title_fontital == null)    { syndicate.title_fontital = false; }
if (syndicate.date_fontface == null)     { syndicate.date_fontface = 'Geneva, Arial, sans-serif'; }
if (syndicate.date_fontsize == null)     { syndicate.date_fontsize = '1'; }
if (syndicate.date_fontcolor == null)    { syndicate.date_fontcolor = '#6699cc'; }
if (syndicate.date_fontbold == null)     { syndicate.date_fontbold = false; }
if (syndicate.date_fontital == null)     { syndicate.date_fontital = false; }
if (syndicate.date_fontunder == null)    { syndicate.date_fontunder = false; }
if (syndicate.summary_fontface == null)  { syndicate.summary_fontface = 'Geneva, Arial, sans-serif'; }
if (syndicate.summary_fontsize == null)  { syndicate.summary_fontsize = '2'; }
if (syndicate.summary_fontcolor == null) { syndicate.summary_fontcolor = '#6699cc'; }
if (syndicate.summary_fontbold == null)  { syndicate.summary_fontbold = false; }
if (syndicate.summary_fontital == null)  { syndicate.summary_fontital = false; }
if (syndicate.summary_fontunder == null) { syndicate.summary_fontunder = false; }

if (syndicate.title_maxlength == null)   { syndicate.title_maxlength = 0; }
if (syndicate.summary_maxlength == null) { syndicate.summary_maxlength = 0; }

if (syndicate.bgcolor == null)           { syndicate.bgcolor = '#ffffff'; }
if (!syndicate.max_articles)             { syndicate.max_articles = syndicate.article_title.length; }  // !syndicate.max_articles catches null and zero
if (syndicate.display_date == null)      { syndicate.display_date = true; }
if (syndicate.display_summaries == null) { syndicate.display_summaries = true; }


// Don't allow user to display too many articles
if (syndicate.max_articles > syndicate.article_title.length) {
  syndicate.max_articles = syndicate.article_title.length;
}

/*
//Function to crop text on word boundaries
function crop_text(text, max_length) {

  // If the string is already small enough, return it unscathed
  if (text.length <= max_length) { return( text ); }

  // If the user has specified a length of 0, it means he wants the whole thing
  if (max_length == 0) { return( text ); }

  // Start looking for a space, leaving space for an elipsis on the end
  var test_length = (max_length - 3);
  if (test_length < 1) { return( '...' ); }   // max_length too small
  while (text.charAt(test_length) != ' ') {
    test_length--;

    // If we didn't find any spaces to break on, return the string broken at max_length
    if (test_length == 0) { return( text.substring(0, max_length - 3) + '...' ); }
  }

  return text.substring(0, test_length) + '...';
}
*/

// List our articles, stopping if the user doesn't want any more
for ( syndicate.index = 0; syndicate.index < syndicate.max_articles ; syndicate.index++ ) {

  /*syndicate.article_title[syndicate.index] = crop_text(syndicate.article_title[syndicate.index], syndicate.title_maxlength);
  syndicate.article_summary[syndicate.index] = crop_text(syndicate.article_summary[syndicate.index], syndicate.summary_maxlength);*/

  document.write('<tr><td bgcolor="' + syndicate.bgcolor + '">');
  document.write('<a href="' + syndicate.article_url[syndicate.index] + '">');
  if (syndicate.title_fontbold)  { document.write('<b>'); }
  if (syndicate.title_fontital)  { document.write('<i>'); }
  document.write('<font color="' + syndicate.title_fontcolor + '" face="' + syndicate.title_fontface + '" size="' + syndicate.title_fontsize + '"');
  if (syndicate.title_style)     { document.write(' style="' + syndicate.title_style + '"'); }
  document.write('>');
  document.write(syndicate.article_title[syndicate.index]);
  document.write('<br></font>');
  if (syndicate.title_fontital)  { document.write('</i>'); }
  if (syndicate.title_fontbold)  { document.write('</b>'); }
  document.write('</a>');

  if (syndicate.display_date) {
    if (syndicate.date_fontbold)  { document.write('<b>'); }
    if (syndicate.date_fontital)  { document.write('<i>'); }
    if (syndicate.date_fontunder) { document.write('<u>'); }
    document.write('<font color="' + syndicate.date_fontcolor + '" face="' + syndicate.date_fontface + '" size="' + syndicate.date_fontsize + '"');
    if (syndicate.date_style)     { document.write(' style="' + syndicate.date_style + '"'); }
    document.write('>');
    document.write(syndicate.article_date[syndicate.index]);
    document.write('<br></font>');
    if (syndicate.date_fontunder) { document.write('</u>'); }
    if (syndicate.date_fontital)  { document.write('</i>'); }
    if (syndicate.date_fontbold)  { document.write('</b>'); }
  }

  if (syndicate.display_summaries) {
    if (syndicate.summary_fontbold)  { document.write('<b>'); }
    if (syndicate.summary_fontital)  { document.write('<i>'); }
    if (syndicate.summary_fontunder) { document.write('<u>'); }
    document.write('<font color="' + syndicate.summary_fontcolor + '" face="' + syndicate.summary_fontface + '" size="' + syndicate.summary_fontsize + '"');
    if (syndicate.summary_style)     { document.write(' style="' + syndicate.summary_style + '"'); }
    document.write('>');
    document.write(syndicate.article_summary[syndicate.index]);
    document.write('<br></font>');
    if (syndicate.summary_fontunder) { document.write('</u>'); }
    if (syndicate.summary_fontital)  { document.write('</i>'); }
    if (syndicate.summary_fontbold)  { document.write('</b>'); }
  }

  document.write('<br></td></tr>\n');
}

// If you want your Webfeeds to be branded, uncomment the following lines.
// To do this, remove the // at the beginning of the next five lines:

//document.write('<tr><td bgcolor="' + syndicate.bgcolor + '">');
//document.write('<a href="#" target="_blank">');
//document.write('<font color="' + syndicate.title_fontcolor + '" face="Verdana, Arial, Helvetica, sans-serif" size="1">');
//document.write('<p><b>Powered by YourSite.com</b></font></a>');
//document.write('<br><br></b></font></td></tr>\n');

