/[suikacvs]/messaging/newsportal/newsportal.php
Suika

Diff of /messaging/newsportal/newsportal.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.23 by wakaba, Sat Dec 1 14:02:09 2001 UTC revision 1.24 by wakaba, Sat Dec 1 15:15:08 2001 UTC
# Line 458  function headerDecode($value) { Line 458  function headerDecode($value) {
458    }    }
459  }  }
460    
 function decode_quoted_pair($value) {  
       return(ereg_replace('\\\\(.)',"\\1",$value));  
 }  
   
461  function getTimestamp($value) {  function getTimestamp($value) {
462    $months=array("Jan"=>1,"Feb"=>2,"Mar"=>3,"Apr"=>4,"May"=>5,"Jun"=>6,"Jul"=>7,"Aug"=>8,"Sep"=>9,"Oct"=>10,"Nov"=>11,"Dec"=>12);    $months=array("Jan"=>1,"Feb"=>2,"Mar"=>3,"Apr"=>4,"May"=>5,"Jun"=>6,"Jul"=>7,"Aug"=>8,"Sep"=>9,"Oct"=>10,"Nov"=>11,"Dec"=>12);
463    $value=str_replace("  "," ",$value);    $value=str_replace("  "," ",$value);
# Line 576  function parse_header($hdr,$number="") { Line 572  function parse_header($hdr,$number="") {
572  }  }
573    
574  function decode_structured_body ($body) {  function decode_structured_body ($body) {
575    ereg("(\"([^\"]+|\\\\.)*\"|\\(([^()]+|\\\\.)*\\)|[^\"])+", $body, $element);    $patterns = array ("/\"((?:[^\"\\\\]+|\\\\.)*)\"/e");
576    return join('-', $element);    $replace = array ("mb_convert_encoding(decode_quoted_pair('\\1'), 'EUC-JP', 'auto')");
577      return preg_replace ($patterns, $replace, $body);
578    }
579    
580    function decode_quoted_pair($value) {
581      $value = ereg_replace('\\\\(\\\\")', "\\1", $value);
582      return ereg_replace('\\\\(.)', "\\1", $value);
583  }  }
584    
585  function decode_body($body,$encoding) {  function decode_body($body,$encoding) {

Legend:
Removed from v.1.23  
changed lines
  Added in v.1.24

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24