'函数名:CodeCookie
  '作 用:Cookie防乱码写入时用
  '参 数:str ---- 字符串
  '返回值:整理后的字符串
  '示 例:
  '**************************************************
  Public Function CodeCookie(str)
   If isNumeric(str) Then str=Cstr(str)
   Dim newstr
   newstr=""
   For i=1 To Len(str)
   newstr=newstr & ascw(mid(str,i,1))
   If i<> Len(str) Then newstr= newstr & "a"
   Next
   CodeCookie=newstr
  End Function
  '**************************************************
'函数名:DecodeCookie
  '作 用:Cookie防乱码读出时用
  '参 数:str ---- 字符串
  '返回值:整理后的字符串
  '示 例:
  '**************************************************
  Public Function DecodeCookie(str)
   DecodeCookie=""
   Dim newstr
   newstr=Split(str,"a")
   For i = LBound(newstr) To UBound(newstr)
   DecodeCookie= DecodeCookie & chrw(newstr(i))
   Next
  End Function