/*******************************************************/
/*            Disable <Enter Key> Function             */
/*            ============================             */
/* Disable the use of the <ENTER> key that issues a    */
/* submit form in IE.                                  */
/*******************************************************/
function disableCR() {
   return !(window.event && window.event.keyCode == 13);
}


/*******************************************************/
/* Checks the contents of any object and verifies that */
/* it is a floating point number.                      */
/*******************************************************/
function validateNumber(field) {
   if (!isWhitespace(field.value)) {
      if (parseFloat(field.value) != field.value) {
         field.value = field.defaultValue;
         field.select();
         field.focus();
         alert('Please enter an numeric value only');
         return false;
      }
   }
   return true;
}

/*******************************************************/
/* Checks the contents of any object and verifies that */
/* it contains numeric characters only.                */
/*******************************************************/
function validateInteger(field) {
   var alowableCharacters = "0123456789";

   if (!isWhitespace(field.value)) {
      for (var i = 0; i < field.value.length; i++) {
         if (alowableCharacters.indexOf(field.value.charAt(i)) == -1) {
            field.value = field.defaultValue;
            field.select();
            field.focus();
            alert('Please enter a integer value only');
            return false;
         }
      }
   }
   return true;
}

/**************************************************************/
/* This function can be used to check whether the user has    */
/* entered anything in a given field. There are two possibile */
/* types of 'emptiness' a form can return - a zero length     */
/* string, or a null value. Here we simply check both these   */
/* options, and return true if either of these are found to   */
/* be true.                                                   */
/**************************************************************/
function isEmpty(s) {
   return ((s == null) || (s.length == 0))
}

/****************************************/
/* Returns true if string s is empty or */
/* whitespace characters only.          */
/****************************************/
function isWhitespace(s) {
   var whitespace = " \t\n\r\s";
   var i;

   // Is s empty?
   if (isEmpty(trim(s))) return true;

   // Search through string's characters one by one
   // until we find a non-whitespace character.
   // When we do, return false; if we don't, return true.

   for (i = 0; i < s.length; i++) {
      // Check that current character is not whitespace.
      var c = s.charAt(i);

      if (whitespace.indexOf(c) == -1)
         return false;
   }

   // All characters are whitespace.
   return true;
}

/***************************************************************/
/* Trims all whitespace from the beginning and end of a string */
/***************************************************************/
function trim(str_String) {
    x = str_String;

    while (x.substring(0,1) == ' ')
       x = x.substring(1);

    while (x.substring(x.length-1,x.length) == ' ')
       x = x.substring(0,x.length-1);

    return x;
}

// Be careful with this pattern.  Longer tokens should be placed before shorter
// tokens to disambiguate them.  For example, parsing "mon_strict" should 
// result in one token "mon_strict" and not two tokens "mon" and a literal
// "_strict".
var tokPat=new RegExp("^month_strict|month|Month|MONTH|yyyy|YYYY|mins|MINS|mon_strict|ampm|AMPM|mon|Mon|MON|min|MIN|dd|DD|mm|MM|yy|YY|hh|HH|ss|SS|m|M|d|D|y|Y|h|H|s|S");

// lowerMonArr is used to map months to their numeric values.
var lowerMonArr={jan:1, feb:2, mar:3, apr:4, may:5, jun:6, jul:7, aug:8, sep:9, oct:10, nov:11, dec:12}

// monPatArr contains regular expressions used for matching abbreviated months
// in a date string.
var monPatArr=new Array();
monPatArr['mon_strict']=new RegExp(/jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec/);
monPatArr['Mon']=new RegExp(/Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec/);
monPatArr['MON']=new RegExp(/JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC/);
monPatArr['mon']=new RegExp("jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec",'i');

// monthPatArr contains regular expressions used for matching full months
// in a date string.
var monthPatArr=new Array();
monthPatArr['month']=new RegExp(/^january|february|march|april|may|june|july|august|september|october|november|december/i);
monthPatArr['Month']=new RegExp(/^January|February|March|April|May|June|July|August|September|October|November|December/);
monthPatArr['MONTH']=new RegExp(/^JANUARY|FEBRUARY|MARCH|APRIL|MAY|JUNE|JULY|AUGUST|SEPTEMBER|OCTOBER|NOVEMBER|DECEMBER/);
monthPatArr['month_strict']=new RegExp(/^january|february|march|april|may|june|july|august|september|october|november|december/);

// cutoffYear is the cut-off for assigning "19" or "20" as century.  Any
// two-digit year >= cutoffYear will get a century of "19", and everything
// else gets a century of "20".
var cutoffYear=50;

function buildDate(dateStr,formatStr) {
   // parse the format string first.
   var tokArr=parseFormatString(formatStr);
   var strInd=0;
   var tokInd=0;
   var intMonth;
   var intDay;
   var intYear;
   var intHour;
   var intMin;
   var intSec;
   var ampm="";
   var strOffset;

   // Create a date object with the current date so that if the user only
   // gives a month or day string, we can still return a valid date.

   var curdate=new Date();
   intMonth=curdate.getMonth()+1;
   intDay=curdate.getDate();
   intYear=curdate.getFullYear();

   // Default time to midnight, so that if given just date info, we return
   // a Date object for that date at midnight.

   intHour=0;
   intMin=0;
   intSec=0;

   // Walk across dateStr, matching the parsed formatStr until we find a 
   // mismatch or succeed.

   while (strInd < dateStr.length && tokInd < tokArr.length) {

      // Start with the easy case of matching a literal.
      if (tokArr[tokInd].type=="literal") {
         if (dateStr.indexOf(tokArr[tokInd].token,strInd)==strInd) {
            // The current position in the string does match the format pattern.
            strInd+=tokArr[tokInd++].token.length;
            continue;
         } else {
            // ACK! There was a mismatch; return error.
            return "\"" + dateStr + "\" does not conform to the expected format: " + formatStr;
         }
      }

      // If we get here, we're matching to a symbolic token.
      switch (tokArr[tokInd].token) {
         case 'm':
         case 'M':
         case 'd':
         case 'D':
         case 'h':
         case 'H':
         case 'min':
         case 'MIN':
         case 's':
         case 'S':

            // Extract one or two characters from the date-time string and if 
            // it's a number, save it as the month, day, hour, or minute, as
            // appropriate.
            curChar=dateStr.charAt(strInd);
            nextChar=dateStr.charAt(strInd+1);
            matchArr=dateStr.substr(strInd).match(/^\d{1,2}/);

            if (matchArr==null) {
               // First character isn't a number; there's a mismatch between
               // the pattern and date string, so return error.
               switch (tokArr[tokInd].token.toLowerCase()) {
                  case 'd': var unit="day"; break;
                  case 'm': var unit="month"; break;
                  case 'h': var unit="hour"; break;
                  case 'min': var unit="minute"; break;
                  case 's': var unit="second"; break;
               }
               return "Bad " + unit + " \"" + curChar + "\" or \"" + curChar +
               nextChar + "\".";
            }

            strOffset=matchArr[0].length;
            switch (tokArr[tokInd].token.toLowerCase()) {
               case 'd': intDay=parseInt(matchArr[0],10); break;
               case 'm': intMonth=parseInt(matchArr[0],10); break;
               case 'h': intHour=parseInt(matchArr[0],10); break;
               case 'min': intMin=parseInt(matchArr[0],10); break;
               case 's': intSec=parseInt(matchArr[0],10); break;
            }
   
            break;

         case 'mm':
         case 'MM':
         case 'dd':
         case 'DD':
         case 'hh':
         case 'HH':
         case 'mins':
         case 'MINS':
         case 'ss':
         case 'SS':

            // Extract two characters from the date string and if it's a 
            // number, save it as the month, day, or hour, as appropriate.
            strOffset=2;
            matchArr=dateStr.substr(strInd).match(/^\d{2}/);

            if (matchArr==null) {
               // The two characters aren't a number; there's a mismatch 
               // between the pattern and date string, so return an error
               // message.
               switch (tokArr[tokInd].token.toLowerCase()) {
                  case 'dd': var unit="day"; break;
                  case 'mm': var unit="month"; break;
                  case 'hh': var unit="hour"; break;
                  case 'mins': var unit="minute"; break;
                  case 'ss': var unit="second"; break;
               }
               return "Bad " + unit + " \"" + dateStr.substr(strInd,2) + "\".";
            }

            switch (tokArr[tokInd].token.toLowerCase()) {
               case 'dd': intDay=parseInt(matchArr[0],10); break;
               case 'mm': intMonth=parseInt(matchArr[0],10); break;
               case 'hh': intHour=parseInt(matchArr[0],10); break;
               case 'mins': intMin=parseInt(matchArr[0],10); break;
               case 'ss': intSec=parseInt(matchArr[0],10); break;
            }

            break;

         case 'y':
         case 'Y':

            // Extract two or four characters from the date string and if it's
            // a number, save it as the year.Convert two-digit years to four
            // digit years by assigning a century of '19' if the year is >= 
            // cutoffYear, and '20' otherwise.
            if (dateStr.substr(strInd,4).search(/\d{4}/) != -1) {
               // Four digit year.
               intYear=parseInt(dateStr.substr(strInd,4),10);
               strOffset=4;
            } else {
               if (dateStr.substr(strInd,2).search(/\d{2}/) != -1) {
                  // Two digit year.
                  intYear=parseInt(dateStr.substr(strInd,2),10);
                  if (intYear>=cutoffYear) {
                     intYear+=1900;
                  } else {
                     intYear+=2000;
                  }
                  strOffset=2;
               } else {
                  // Bad year; return error.
                  return "Bad year \"" + dateStr.substr(strInd,2) + "\". Must be two or four digits.";
               }
            }
            break;

         case 'yy':
         case 'YY':

            // Extract two characters from the date string and if it's a 
            // number, save it as the year.Convert two-digit years to four 
            // digit years by assigning a century of '19' if the year is >= 
            // cutoffYear, and '20' otherwise.
            if (dateStr.substr(strInd,2).search(/\d{2}/) != -1) {
               // Two digit year.
               intYear=parseInt(dateStr.substr(strInd,2),10);
               if (intYear>=cutoffYear) {
                  intYear+=1900;
               } else {
                  intYear+=2000;
               }
               strOffset=2;
            } else {
               // Bad year; return error
               return "Bad year \"" + dateStr.substr(strInd,2) + "\". Must be two digits.";
            }
            break;
         
         case 'yyyy':
         case 'YYYY':

            // Extract four characters from the date string and if it's a 
            // number, save it as the year.
            if (dateStr.substr(strInd,4).search(/\d{4}/) != -1) {
               // Four digit year.
               intYear=parseInt(dateStr.substr(strInd,4),10);
               strOffset=4;
            } else {
               // Bad year; return error.
               return "Bad year \"" + dateStr.substr(strInd,4) + "\". Must be four digits.";
            }
            break;
         
         case 'mon':
         case 'Mon':
         case 'MON':
         case 'mon_strict':

            // Extract three characters from dateStr and parse them as
            // lower-case, mixed-case, or upper-case abbreviated months, as appropriate.
            monPat=monPatArr[tokArr[tokInd].token];
            if (dateStr.substr(strInd,3).search(monPat) != -1) {
               intMonth=lowerMonArr[dateStr.substr(strInd,3).toLowerCase()];
            } else {
               // Bad month, return error.
               switch (tokArr[tokInd].token) {
                  case 'mon_strict': caseStat="lower-case"; break;
                  case 'Mon': caseStat="mixed-case"; break;
                  case 'MON': caseStat="upper-case"; break;
                  case 'mon': caseStat="between Jan and Dec"; break;
               }
               return "Bad month \"" + dateStr.substr(strInd,3) + "\". Must be " + caseStat + ".";
            }
            strOffset=3;
            break;

         case 'month':
         case 'Month':
         case 'MONTH':
         case 'month_strict':

            // Extract a full month name at strInd from dateStr if possible.
            monPat=monthPatArr[tokArr[tokInd].token];
            matchArray=dateStr.substr(strInd).match(monPat);
            if (matchArray==null) {
               // Bad month, return error.
               return "Can't find a month beginning at \"" + dateStr.substr(strInd) + "\".";
            }
   
            // It's a good month.
            intMonth=lowerMonArr[matchArray[0].substr(0,3).toLowerCase()];
            strOffset=matchArray[0].length;
            break;

         case 'ampm':
         case 'AMPM':
            matchArr=dateStr.substr(strInd).match(/^(am|pm|AM|PM|a\.m\.|p\.m\.|A\.M\.|P\.M\.)/);
            if (matchArr==null) {
               // There's no am/pm in the string.Return error msg.
               return "Missing am/pm designation.";
            }

            // Store am/pm value for later (as just am or pm, to make things easier later).
            if (matchArr[0].substr(0,1).toLowerCase() == "a") {
               // This is am.
               ampm = "am";
            } else {
               ampm = "pm";
            }
            strOffset = matchArr[0].length;
            break;
      }

      strInd += strOffset;
      tokInd++;
   }

   if (tokInd != tokArr.length || strInd != dateStr.length) {
      /* We got through the whole date string or format string, but there's 
         more data in the other, so there's a mismatch. */
      return "\"" + dateStr + "\" is either missing desired information or has more information than the expected format: " + formatStr;
   }

   // Make sure all components are in the right ranges.
   if (intMonth < 1 || intMonth > 12) {
      return "Month must be between 1 and 12.";
   }

   if (intDay < 1 || intDay > 31) {
      return "Day must be between 1 and 31.";
   }

   // Make sure user doesn't put 31 for a month that only has 30 days
   if ((intMonth == 4 || intMonth == 6 || intMonth == 9 || intMonth == 11) && intDay == 31) {
      return "Month "+intMonth+" doesn't have 31 days!";
   }

   // Check for February date validity (including leap years) 
   if (intMonth == 2) {
      // figure out if "year" is a leap year; don't forget that
      // century years are only leap years if divisible by 400
      var isleap=(intYear%4==0 && (intYear%100!=0 || intYear%400==0));
      if (intDay > 29 || (intDay == 29 && !isleap)) {
         return "February " + intYear + " doesn't have " + intDay + " days!";
      }
   }

   // Check that if am/pm is not provided, hours are between 0 and 23.
   if (ampm == "") {
      if (intHour < 0 || intHour > 23) {
         return "Hour must be between 0 and 23 for military time.";
      }
   } else {
   // non-military time, so make sure it's between 1 and 12.
      if (intHour < 1|| intHour > 12) {
         return "Hour must be between 1 and 12 for standard time.";
      }
   }

   // If user specified amor pm, convert intHour to military.
   if (ampm=="am" && intHour==12) {
      intHour=0;
   }

   if (ampm=="pm" && intHour < 12) {
      intHour += 12;
   }

   if (intMin < 0 || intMin > 59) {
      return "Minute must be between 0 and 59.";
   }

   if (intSec < 0 || intSec > 59) {
      return "Second must be between 0 and 59.";
   }

return new Date(intYear,intMonth-1,intDay,intHour,intMin,intSec);
}

function dateCheck(dateStr,formatStr) {
   var myObj = buildDate(dateStr,formatStr);
   if (typeof myObj == "object") {
      return true;
   } else {
      return false;
   }
}

function parseFormatString (formatStr) {
   var tokArr=new Array;
   var tokInd=0;
   var strInd=0;
   var foundTok=0;
    
   while (strInd < formatStr.length) {
      if (formatStr.charAt(strInd)=="%" && (matchArray=formatStr.substr(strInd+1).match(tokPat)) != null) {
         strInd+=matchArray[0].length+1;
         tokArr[tokInd++]=new FormatToken(matchArray[0],"symbolic");
      } else {
         // No token matched current position, so current character should be saved as a required literal.
         if (tokInd>0 && tokArr[tokInd-1].type=="literal") {
            // Literal tokens can be combined.Just add to the last token.
            tokArr[tokInd-1].token+=formatStr.charAt(strInd++);
         } else {
            tokArr[tokInd++]=new FormatToken(formatStr.charAt(strInd++), "literal");
         }
      }
   }
   return tokArr;
}

function FormatToken (token, type) {
   this.token=token;
   this.type=type;
}

function limitTextarea(el,maxLines,maxChar) {
   if(!el.x) {
     el.x=uniqueInt();
     el.onblur=function(){clearInterval(window['int'+el.x])}
   }

   window['int'+el.x]=setInterval(function() {
      var lines=el.value.replace(/\r/g,'').split('\n'), i=lines.length, lines_removed, char_removed;
      if(maxLines&&i>maxLines) {
         alert('You can not enter\nmore than '+maxLines+' lines');
         lines=lines.slice(0,maxLines);
         lines_removed=1;
      }

      if(maxChar) {
         i=lines.length;
         while(i-->0)
            if(lines[i].length>maxChar) {
               lines[i]=lines[i].slice(0,maxChar);
               char_removed=1;
            }

         if(char_removed)alert('You can not enter more\nthan '+maxChar+' characters in total')
      }

      if(char_removed||lines_removed)el.value=lines.join('\n')
   },50);
}

function uniqueInt() {
   var num,maxNum=100000;
   if(!uniqueInt.a||maxNum<=uniqueInt.a.length)uniqueInt.a=[];
      do num=Math.ceil(Math.random()*maxNum);
 
  while(uniqueInt.a.hasMember(num))
      uniqueInt.a[uniqueInt.a.length]=num;
 
 return num
}

Array.prototype.hasMember=function(testItem) {
   var i=this.length;
   while(i-->0)if(testItem==this[i])return 1;
      return 0
};

function base64_decode( data ) {
    // http://kevin.vanzonneveld.net
    // +   original by: Tyler Akins (http://rumkin.com)
    // +   improved by: Thunder.m
    // +      input by: Aman Gupta
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // +   bugfixed by: Onno Marsman
    // +   bugfixed by: Pellentesque Malesuada
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // +      input by: Brett Zamir
    // +   bugfixed by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // -    depends on: utf8_decode
    // *     example 1: base64_decode('S2V2aW4gdmFuIFpvbm5ldmVsZA==');
    // *     returns 1: 'Kevin van Zonneveld'
 
    // mozilla has this native
    // - but breaks in 2.0.0.12!
    //if (typeof window['btoa'] == 'function') {
    //    return btoa(data);
    //}
 
    var b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
    var o1, o2, o3, h1, h2, h3, h4, bits, i = 0, ac = 0, dec = "", tmp_arr = [];
 
    if (!data) {
        return data;
    }
 
    data += '';
 
    do {  // unpack four hexets into three octets using index points in b64
        h1 = b64.indexOf(data.charAt(i++));
        h2 = b64.indexOf(data.charAt(i++));
        h3 = b64.indexOf(data.charAt(i++));
        h4 = b64.indexOf(data.charAt(i++));
 
        bits = h1<<18 | h2<<12 | h3<<6 | h4;
 
        o1 = bits>>16 & 0xff;
        o2 = bits>>8 & 0xff;
        o3 = bits & 0xff;
 
        if (h3 == 64) {
            tmp_arr[ac++] = String.fromCharCode(o1);
        } else if (h4 == 64) {
            tmp_arr[ac++] = String.fromCharCode(o1, o2);
        } else {
            tmp_arr[ac++] = String.fromCharCode(o1, o2, o3);
        }
    } while (i < data.length);
 
    dec = tmp_arr.join('');
    dec = utf8_decode(dec);
 
    return dec;
}

function base64_encode( data ) {
    // http://kevin.vanzonneveld.net
    // +   original by: Tyler Akins (http://rumkin.com)
    // +   improved by: Bayron Guevara
    // +   improved by: Thunder.m
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // +   bugfixed by: Pellentesque Malesuada
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // -    depends on: utf8_encode
    // *     example 1: base64_encode('Kevin van Zonneveld');
    // *     returns 1: 'S2V2aW4gdmFuIFpvbm5ldmVsZA=='
 
    // mozilla has this native
    // - but breaks in 2.0.0.12!
    //if (typeof window['atob'] == 'function') {
    //    return atob(data);
    //}
        
    var b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
    var o1, o2, o3, h1, h2, h3, h4, bits, i = ac = 0, enc="", tmp_arr = [];
 
    if (!data) {
        return data;
    }
 
    data = utf8_encode(data+'');
    
    do { // pack three octets into four hexets
        o1 = data.charCodeAt(i++);
        o2 = data.charCodeAt(i++);
        o3 = data.charCodeAt(i++);
 
        bits = o1<<16 | o2<<8 | o3;
 
        h1 = bits>>18 & 0x3f;
        h2 = bits>>12 & 0x3f;
        h3 = bits>>6 & 0x3f;
        h4 = bits & 0x3f;
 
        // use hexets to index into b64, and append result to encoded string
        tmp_arr[ac++] = b64.charAt(h1) + b64.charAt(h2) + b64.charAt(h3) + b64.charAt(h4);
    } while (i < data.length);
    
    enc = tmp_arr.join('');
    
    switch( data.length % 3 ){
        case 1:
            enc = enc.slice(0, -2) + '==';
        break;
        case 2:
            enc = enc.slice(0, -1) + '=';
        break;
    }
 
    return enc;
}

/**************************************************/
/* Display a popup window centered on the screen. */
/* Width and Height are sipplied by the caller.   * /
/**************************************************/
var win= null;

function openWindow(mypage,myname,w,h,scroll,resizable,status,menubar,toolbar) {
  if (myname == null) {
     myname = '';
  }
  if (w == null) {
     w = 0;
  }
  if (h == null) {
     h = 0;
  }
  if (scroll == null) {
     scroll = 'no';
  }
  if (resizable == null) {
     resizable = 'no';
  }
  if (status == null) {
     status = 'no';
  }
  if (menubar == null) {
     menubar = 'no';
  }
  if (toolbar == null) {
     toolbar = 'no';
  }

  var winl = (screen.availWidth-w)/2;
  var wint = (screen.availHeight-h)/2;
  var settings  ='height='+h+',';
      settings +='width='+w+',';
      settings +='top='+wint+',';
      settings +='left='+winl+',';
      settings +='scrollbars='+scroll+',';
      settings +='resizable='+resizable+',';
      settings +='status='+status+',';
      settings +='menubar='+menubar+',';
      settings +='toolbar='+toolbar;
  win=window.open(mypage,myname,settings);
  if(parseInt(navigator.appVersion) >= 4)
     win.window.focus();
  if (!win.opener)
     win.opener = self;
}

/*******************************************************/
/* Display a popup window centered on the screen. The  */
/* window will be half the size of a maximized browser */
/* window and centered in the middle of the screen     */
/*******************************************************/
function centerWindowScreen(mypage,myname,scroll) {
  var w = 480, h = 340;
  if (document.all || document.layers) {
    w = screen.availWidth/2;
    h = screen.availHeight/2;
  }
  newWindow(mypage,myname,w,h,scroll);
}

/***********************************************************/
/* Display a popup window centered in the current browser. */
/***********************************************************/
function centerWindowBrowser(mypage,myname,scroll) {
  var w = 480, h = 340;
  if (document.all) {
    /* the following is only available after onLoad */
    w = document.body.clientWidth/2;
    h = document.body.clientHeight/2;
  } else {
    if (document.layers) {
      w = window.innerWidth/2;
      h = window.innerHeight/2;
    }
  }
  newWindow(mypage,myname,w,h,scroll);
}

/*****************************************************************/
/* Load a URL into the parent window and close the popup window. */
/*****************************************************************/
function UrlLoad(url) {
    window.onerror = supressError;
    opener.location.href = url;
    setTimeout('self.close()',10);
}

function supressError() {
    return true;
}

function addslashes(str) {
	str=str.replace(/\'/g,'\\\'');
	str=str.replace(/\"/g,'\\"');
	str=str.replace(/\\/g,'\\\\');
	str=str.replace(/\0/g,'\\0');
	return str;
}

function stripslashes(str) {
	str=str.replace(/\\'/g,'\'');
	str=str.replace(/\\"/g,'"');
	str=str.replace(/\\\\/g,'\\');
	str=str.replace(/\\0/g,'\0');
	return str;
}
