



// 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 ] = 'Parker scores 19 to lead San Antonio past Clippers';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Parker_scores_19_to_lead_San_Antonio_past_Clippers.htm';
  syndicate.article_date[ syndicate.index ] = 'Jan 9, 2009 - 12:45:37 AM';
  syndicate.article_summary[ syndicate.index ] = 'It was an off night for Tim Duncan, but a good one for the San Antonio Spurs.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Kobe, Lakers come back to win Game 1 over Spurs';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/Los_Angeles_Lakers_86/Kobe_Lakers_come_back_to_win_Game_1_over_Spurs.htm';
  syndicate.article_date[ syndicate.index ] = 'May 22, 2008 - 9:04:20 AM';
  syndicate.article_summary[ syndicate.index ] = 'Kobe Bryant and the Los Angeles Lakers waited until the third quarter to get going. Once they did, the San Antonio Spurs couldn\'t stop them. Bryant scored all but two of his 27 points after halftime, including a go-ahead, 10-foot jumper in the lane with 23.9 seconds remaining, and the Lakers rallied from a 20-point deficit to beat the Spurs 89-85 on Wednesday night in Game 1 of the Western Conference finals.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Spurs beat Hornets 91-82, advance to West finals';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Spurs_beat_Hornets_91-82_advance_to_West_finals.htm';
  syndicate.article_date[ syndicate.index ] = 'May 20, 2008 - 7:32:55 AM';
  syndicate.article_summary[ syndicate.index ] = 'A title defense endures for the playoff-savvy San Antonio Spurs. Manu Ginobili scored 26 points, hitting four free throws in the final minute, sending the Spurs to the Western Conference finals with a 91-82 victory over the New Orleans Hornets on Monday night in Game 7 of their second-round series.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Ginobili, Duncan help Spurs force Game 7';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Ginobili_Duncan_help_Spurs_force_Game_7.htm';
  syndicate.article_date[ syndicate.index ] = 'May 16, 2008 - 6:55:24 AM';
  syndicate.article_summary[ syndicate.index ] = 'The San Antonio Spurs\' Big Three came through. Now they have to win one on the road to keep their title defense alive. Manu Ginobili scored 25 points, Tim Duncan had 20 points and 15 rebounds, and Tony Parker added 15 points in the Spurs\' 99-80 victory over the New Orleans Hornets in Game 6 on Thursday night.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Hornets beat Spurs 101-79 to take 3-2 series lead';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/New_Orleans_Hornets_74/Hornets_beat_Spurs_101-79_to_take_3-2_series_lead.htm';
  syndicate.article_date[ syndicate.index ] = 'May 14, 2008 - 2:15:35 AM';
  syndicate.article_summary[ syndicate.index ] = 'David West and the New Orleans Hornets sure looked happy to be at home. West had career playoff highs of 38 points, 14 rebounds and five blocked shots, lifting New Orleans to a 101-79 victory over the San Antonio Spurs on Tuesday night and a 3-2 series lead.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Tim Duncan scores 22 as Spurs beat Hornets 100-80';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Tim_Duncan_scores_22_as_Spurs_beat_Hornets_100-80.htm';
  syndicate.article_date[ syndicate.index ] = 'May 12, 2008 - 7:30:47 AM';
  syndicate.article_summary[ syndicate.index ] = 'Tim Duncan had 22 points and 15 rebounds, and the San Antonio Spurs beat the New Orleans Hornets 100-80 on Sunday night in Game 4 to even the Western Conference semifinals at 2-2.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Parker, Ginobili both score 31; Spurs beat Hornets in Game 3';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Parker_Ginobili_both_score_31_Spurs_beat_Hornets_in_Game_3.htm';
  syndicate.article_date[ syndicate.index ] = 'May 9, 2008 - 7:03:57 AM';
  syndicate.article_summary[ syndicate.index ] = 'There was no third-quarter breakdown for the San Antonio Spurs on Thursday night, just the desperate play of a team whose quest for a second straight NBA title was on the line. Tony Parker and Manu Ginobili both scored 31 points to lead the Spurs to a 110-99 victory over the New Orleans Hornets in Game 3 of the Western Conference semifinals.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Paul leads Hornets to another easy win over Spurs in Game 2';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/New_Orleans_Hornets_74/Paul_leads_Hornets_to_another_easy_win_over_Spurs_in_Game_2.htm';
  syndicate.article_date[ syndicate.index ] = 'May 6, 2008 - 2:57:25 AM';
  syndicate.article_summary[ syndicate.index ] = 'Shutting down David West only gave the San Antonio Spurs front-row seats for the Chris Paul show. With razzle-dazzle dribbles and a driving floater that couldn\'t miss, Paul had 30 points and 12 assists, leading the New Orleans Hornets to a 102-84 victory Monday night and a 2-0 lead over the Spurs in their second-round series.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Duncan agrees to 2 more years with Spurs';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Duncan_agrees_to_2_more_years_with_Spurs.htm';
  syndicate.article_date[ syndicate.index ] = 'Oct 30, 2007 - 2:33:03 PM';
  syndicate.article_summary[ syndicate.index ] = 'Tim Duncan has agreed to a two-year, $40 million contract extension with the San Antonio Spurs, an official familiar with the negotiations said Tuesday.';
  syndicate.index++;  syndicate.article_title[ syndicate.index ] = 'Spurs win 4th NBA title in 9 years';
  syndicate.article_url[ syndicate.index ] = 'http://www.mopsquad.com/artman2/publish/San_Antonio_Spurs_82/Spurs_win_4th_NBA_title_in_9_years.htm';
  syndicate.article_date[ syndicate.index ] = 'Jun 15, 2007 - 7:43:42 AM';
  syndicate.article_summary[ syndicate.index ] = 'The San Antonio Spurs win their third title in five years, and fourth in the last nine seasons, by sweeping Cleveland 83-82 in Game Four of the NBA Finals.';
  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');

