// portfolio

function EDG_OnChangeImage(iInc)
{
  var iFolio = iCurFolio + iInc;

  if (iInc != 0)
  {
    if (iFolio == iCurFolio)
       return; // no change

    if (iFolio < 0 || iFolio >= iMaxFolio)
    {
       return;
    }
  }

  if (iFolio == 0)
	document.prev.src = strPrevDisabled 
  else
	document.prev.src = strPrev

  if (iFolio >= iMaxFolio-1)
	document.next.src = strNextDisabled
  else
	document.next.src = strNext

  iCurFolio = iFolio;

  if (iMaxFolio == 0)
     strID = "0000"

  var strImage = "/scripts/prpv.dll?photo?s=" + sSize + "&c=" + strColor + "&i=" + strID + "PORT";

  var strImageNum;
  strImageNum = iCurFolio.toString();
  var iLen = strImageNum.length;
  var iMax = 6-iLen;
  for (i=0; i<iMax; i+=1)
  {
     strImage += "0"; 
  }
  strImage += strImageNum;
  document.folio.src = strImage; 
}

