var tmsTitle = 'TMS Testimonial';
var tms = '<p>SPT is a trusted business partner to Tribune Media Services ' +
  'as we continue to expand the amount of content we make available via ' +
  'our on demand architecture.  SPT understands our business needs and is ' +
  'able to translate this into technical requirements and high quality ' +
  'applications.  SPT is also able to create the kind of technical ' +
  'documentation needed to communicate to both business and technology ' +
  'contacts at our clients.  Additionally, SPT is able to deliver to our ' +
  'demanding deadlines.</p> ' +
  '<p><b>Gregory Loose</b><br/>Director, Product Development<br/>' +
  'Tribune Media Services</p>';
var mvccTitle = 'CSSIA Testimonial';
var mvcc = '<p>"To develop our Web Based Network Resource Scheduling application, ' +
  'CSSIA needed a development partner with technical expertise, project management ' +
  'skills, and the willingness to adapt flexibly to our needs.  Sans Pareil Technologies ' +
  'met and exceeded our expectations.</p><p>Despite the complexity of the project and ' +
  'requirements that we refined over time, SPT delivered a superior product.  We were ' +
  'impressed with SPT\'s ability to adjust to change and desire to go the extra mile. ' +
  'Utilizing a solid quality assurance methodology, they delivered a reliable, ' +
  'cross-platform Web application.</p> ' +
  '<p>CSSIA plans to engage Sans Pareil Technologies for future enhancements and ' +
  'customization of the application, not only for CSSIA but also our member ' +
  'institutions. It was a pleasure working with the SPT team."</p> ' +
  '<p><b>Erich J. Spengler</b><br>Director/PI<br>NSF ATE Regional Center CSSIA</p>';

var cldTitle = 'PharmARC Testimonial';
var cld = '<p>"We have worked with Sans Pareil Technologies for building the ' +
  'application for a Key Opinion Leader project.</p>' +
  '<p>During the execution of this project, SPT had a proactive, understanding and ' +
  'patient approach. The user requirements changed a few times during the course of ' +
  'the project and SPT did a tremendous job in being flexible to accommodate the ' +
  'changes. The team was very responsive and proactive in terms of getting back ' +
  'to us on the queries we had every now and then.</p>' +
  '<p>Overall, the job done was of good quality in terms of both the execution ' +
  'and documentation.</p><p>One thing that SPT could focus more on, is sharing ' +
  'detailed project plans from during the course of execution (timelines, milestones, ' +
  'caveats/contingencies), and continuous follow-up and monitoring of the same on ' +
  'regular basis."</p>' +
  '<p><b>Amit Sadana</b><br/>President<br/>PharmARC</p>';

var lsastudiesTitle = 'LSA Studies Testimonial';
var lsastudies = '<p>"We contact Sans Pareil Technologies for helping us set up ' +
  'our intranet system.  After evaluating other available software and service ' +
  'providers, we chose to engage SPT in helping us set up our company web mail ' +
  'system, our internal performance review system as well as laboaratory ' +
  'scheduling system.  The range of products offered by SPT and their technical ' +
  'competence was a key factor in us chosing them as our preferred service provider. ' +
  'We have been very happy with the products and services offered by SPT."</p>';

function collapse( client )
{
  var element = document.getElementById( client );
  if ( element == null ) return;

  while ( element.childNodes.length > 0 )
  {
    element.removeChild( element.firstChild );
  }

  var control = document.createElement( 'a' );
  control.setAttribute( 'id', client + 'Link' );
  control.setAttribute( 'href', 'javascript:expand("' + client + '")' );
  control.appendChild( document.createTextNode( '+ Testimonial' ) );
  element.appendChild( control );
}

function expand( client )
{
  var element = document.getElementById( client );
  if ( element == null ) return;

  var control = document.getElementById( client + 'Link' );
  element.removeChild( control );

  var outer = document.createElement( 'div' );
  outer.setAttribute( 'id', 'borderdiv' );

  control = document.createElement( 'a' );
  control.setAttribute( 'id', client + 'Link' );
  control.setAttribute( 'href', 'javascript:collapse("' + client + '")' );
  control.appendChild( document.createTextNode( '- Testimonial' ) );
  outer.appendChild( control );

  var inner = document.createElement( 'div' );
  inner.style[ 'border' ] = '3px #cb2519 solid';
  inner.style[ 'margin-left' ] = '50px';
  inner.setAttribute( 'id', 'testimonialBox' );

  var titlebar = document.createElement( 'div' );
  titlebar.setAttribute( 'id', 'testimonialTitle' );
  titlebar.innerHTML = eval( client + 'Title' );
  inner.appendChild( titlebar );

  var content = document.createElement( 'div' );
  content.setAttribute( 'id', 'testimonial' );
  content.innerHTML = eval( client );
  inner.appendChild( content );

  outer.appendChild( inner );
  element.appendChild( outer );
}
