<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<HTML>
-<HEAD>
- <META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=shift_jis">
- <TITLE>\95Ï\8dX\97\9a\97ð</TITLE>
- <META NAME="GENERATOR" CONTENT="OpenOffice.org 1.1.3 (Win32)">
- <META NAME="CREATED" CONTENT="20050130;2310982">
- <META NAME="CHANGED" CONTENT="20050130;2372139">
-</HEAD>
-<BODY LANG="ja-JP" DIR="LTR">
-<H2>\95Ï\8dX\97\9a\97ð</H2>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.37</SPAN></FONT>\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2005/1/30</SPAN></FONT>\81j</H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">JIS</SPAN></FONT>\82Ì\83}\83b\83`\83\93\83O\82Ì\83o\83O\82ð\8dÄ\82Ñ\8fC\90³\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.36</SPAN></FONT>\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2004/11/13</SPAN></FONT>\81j</H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">JIS</SPAN></FONT>\82Ì\83}\83b\83`\83\93\83O\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.35</SPAN></FONT>\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2004/9/26</SPAN></FONT>\81j</H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_send_mail</SPAN></FONT>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.341</SPAN></FONT>\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2004/9/16</SPAN></FONT>\81j</H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_kana</SPAN></FONT>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.34</SPAN></FONT>\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2004/9/15</SPAN></FONT>\81j</H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_kana</SPAN></FONT>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.33</SPAN></FONT>\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2004/8/27</SPAN></FONT>\81j</H3>
-<UL>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_encode_numericentity,
- mb_decode_numericentity</SPAN></FONT>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B
- </P>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_encoding</SPAN></FONT>\82Å<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">UTF-16</SPAN></FONT>\82©\82ç\82Ì\95Ï\8a·\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B
- </P>
- <LI><P STYLE="margin-bottom: 0cm">\83V\83t\83g<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">JIS</SPAN></FONT>\82Ì\8f\88\97\9d\82ð<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">SJIS-WIN</SPAN></FONT>\8cÝ\8a·\82É\82µ\82Ü\82µ\82½\81B<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR>mbstring</SPAN></FONT>\96{\89Æ\82Æ\82Í\88Ù\82È\82è\81C<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">SJIS</SPAN></FONT>\82Æ<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">SJIS-WIN</SPAN></FONT>\82Ì\93®\8dì\82Í\93¯\82¶\82Å\82·\81B
- </P>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strcut</SPAN></FONT>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B
- </P>
- <LI><P>\95Ï\8dX\97\9a\97ð\82ð<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">HTML</SPAN></FONT>\82É\95Ï\82¦\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.32(2004/8/19)</SPAN></FONT></H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_http_input,
- mb_http_output, mb_output_handler
- </SPAN></FONT>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR></SPAN></FONT>\82½\82¾\82µ\81C<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_http_input</SPAN></FONT>\82É\8aÖ\82µ\82Ä\82Í\95¶\8e\9a\83R\81[\83h\95Ï\8a·\82ð\8ds\82í\82È\82¢\82½\82ß\81C\8fí\82É<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">FALSE</SPAN></FONT>\82ð\95Ô\82µ\82Ü\82·\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.31(2004/8/16)</SPAN></FONT></H3>
-<UL>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_decode_mimeheader</SPAN></FONT>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½
- </P>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_variables</SPAN></FONT>\82Ì\8f\89\8aú\90Ý\92è\83`\83F\83b\83N\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.3(2004/8/8)</SPAN></FONT></H3>
-<UL>
- <LI><P STYLE="margin-bottom: 0cm">\83o\83O\82Â\82Ô\82µ<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR></SPAN></FONT>\93ü\82ê\8eq\82Ì\83t\83@\83\93\83N\83V\83\87\83\93\82Å\93ñ\8fd\90é\8c¾\82É\82È\82Á\82Ä\82µ\82Ü\82¤\8fê\8d\87\82ª\82 \82é\82Ì\82Å\8aO\95\94\82É\8fo\82µ\82Ü\82µ\82½\81B
- </P>
- <LI><P STYLE="margin-bottom: 0cm">\83o\83O\82Â\82Ô\82µ<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR>mb_strcut</SPAN></FONT>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½
- </P>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_encode_mimeheader,
- mb_decode_mimeheader</SPAN></FONT>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B
- </P>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_variables</SPAN></FONT>\82Å\94z\97ñ\82©\82ç\82Ì\95Ï\8a·\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR></SPAN></FONT>\82±\82ê\82É\94º\82¢<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_variables</SPAN></FONT>\82ð<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2</SPAN></FONT>\83p\83^\81[\83\93\82É\82µ\81C\8f\89\8aú\90Ý\92è\82Å\95Ï\8dX\82Å\82«\82é\82æ\82¤\82É\82µ\82Ü\82µ\82½\81B<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR></SPAN></FONT>\8f\89\8aú\90Ý\92è\83t\83@\83C\83\8b\82Ì<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">convert-variables-arrayonly</SPAN></FONT>\82ª<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">no</SPAN></FONT>\82Ì\8fê\8d\87\81i\83f\83t\83H\83\8b\83g\81j\81C\82±\82ê\82Ü\82Å\82Æ\93¯\82¶\82æ\82¤\82É\94z\97ñ\82Å\82È\82\82Ä\82à\95Ï\8a·\82µ\82Ü\82·\81B\82Ü\82½\81C\8dÅ\8f\89\82Ì\97v\91f\82ª\94z\97ñ\82Ì\8fê\8d\87\81C\82»\82ê\82¾\82¯\82ð\95Ï\8a·\82µ\82Ü\82·\81B\82½\82¾\82µ\81C\82±\82¿\82ç\82Ì\8fê\8d\87\81C\8cÄ\82Ñ\8fo\82µ\8e\9e\82É\88ø\90\94\82É<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">&</SPAN></FONT>\82ð\95t\82¯\82Ä\96¾\8e¦\93I\82É\8eQ\8fÆ\93n\82µ\82É\82·\82é\95K\97v\82ª\82 \82è\82Ü\82·\81B<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR>convert-variables-arrayonly</SPAN></FONT>\82ª<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">no</SPAN></FONT>\82Å\82È\82¢\8fê\8d\87\81C\95Ï\8a·\82·\82é\88ø\90\94\82Í\94z\97ñ\82¾\82¯\82É\82È\82è\82Ü\82·\81B\82»\82Ì\91ã\82í\82è\81C<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">&</SPAN></FONT>\82Í\95s\97v\82Å\82·\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">Ver.0.25(2004/7/7)</SPAN></FONT></H3>
-<UL>
- <LI><P>\83o\83O\82Â\82Ô\82µ<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR></SPAN></FONT>\93ü\82ê\8eq\82Ì\83t\83@\83\93\83N\83V\83\87\83\93\82Å\93ñ\8fd\90é\8c¾\82É\82È\82Á\82Ä\82µ\82Ü\82¤\8fê\8d\87\82ª\82 \82é\82Ì\82Å\8aO\95\94\82É\8fo\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">ver.0.24(2004/6/8)</SPAN></FONT></H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strpos,
- mb_substr_count, mb_preferred_mime_name</SPAN></FONT>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">ver.0.23(2004/5/19)</SPAN></FONT></H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_encoding</SPAN></FONT>\82Å<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">UTF-16</SPAN></FONT>\82Ö\82Ì\95Ï\8a·\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR><BR>usage:<BR>$str
- = mb_convert_encoding($str, 'UTF-16', 'EUC-JP,
- UTF-8');<BR><BR></SPAN></FONT>\95Ô\82·\82Ì\82Í<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">BOM</SPAN></FONT>\82È\82µ\82Ì\83r\83b\83O\81E\83G\83\93\83f\83B\83A\83\93\82É\82È\82è\82Ü\82·\81B
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">ver.0.22(2004/5/11)</SPAN></FONT></H3>
-<UL>
- <LI><P STYLE="margin-bottom: 0cm">\83o\83O\82Â\82Ô\82µ
- </P>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_variables</SPAN></FONT>\82ð\8eb\92è\83T\83|\81[\83g
- </P>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strwidth</SPAN></FONT>\82ð\83T\83|\81[\83g
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">ver.0.21(2004/4/28)</SPAN></FONT></H3>
-<UL>
- <LI><P STYLE="margin-bottom: 0cm">\8f\89\8aú\90Ý\92è\82ð<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb-emulator.ini</SPAN></FONT>\82©\82ç\93Ç\82Þ\82æ\82¤\82É\95Ï\8dX
- </P>
- <LI><P STYLE="margin-bottom: 0cm"><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">EUC</SPAN></FONT>\82Æ<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">UTF-8</SPAN></FONT>\8aÔ\82ð\92¼\90Ú\95Ï\8a·\82·\82é\82æ\82¤\82É\95Ï\8dX
- </P>
- <LI><P>\83o\83O\82Â\82Ô\82µ
- </P>
-</UL>
-<H3><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">ver.0.2(2004/4/27)</SPAN></FONT></H3>
-<UL>
- <LI><P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">jcode</SPAN></FONT>\82ð\8eg\82í\82È\82¢\8c`\82Å\93Æ\97§\82µ\82Ü\82µ\82½\81B<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">12</SPAN></FONT>\8aÖ\90\94\83T\83|\81[\83g<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><BR>mb_language,
- mb_internal_encoding, mb_convert_encoding, mb_convert_kana,
- mb_send_mail, mb_strimwidth, mb_detect_encoding, mb_detect_order,
- mb_strlen, mb_substr, mb_strcut, mb_strrpos </SPAN></FONT>
- </P>
-</UL>
-<H2>\8aÖ\90\94\83T\83|\81[\83g\8fó\8bµ\81i<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">2004/8/19</SPAN></FONT>\81j</H2>
-<TABLE CELLPADDING=2 CELLSPACING=2>
- <TR>
- <TD WIDTH=150>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US"><B>mbstring</B></SPAN></FONT><B>\8aÖ\90\94\96¼</B></P>
- </TD>
- <TD WIDTH=300>
- <P><B>\8d¡\8cã\82Ì\83T\83|\81[\83g\97\\92è</B></P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_case</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\89Â\94\\82¾\82¯\82Ç\8c\8b\8d\\91å\95Ï\82»\82¤\81B\82 \82Ü\82è\8eg\82¢\82»\82¤\82É\82È\82¢\8bC\82ª\82·\82é\81B\82à\82µ\83j\81[\83Y\82ª\82 \82ê\82Î</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_encoding</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_kana</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_convert_variables</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_decode_mimeheader</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_decode_numericentity</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_detect_encoding</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_detect_order</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_encode_mimeheader</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_encode_numericentity</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_match</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_replace</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search_getpos</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search_getregs</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search_init</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search_pos</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search_regs</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search_setpos</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg_search</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_ereg</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_eregi_replace</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_eregi</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_get_info</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_http_input</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý\81i\8fí\82É<FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">FALSE</SPAN></FONT>\82ð\95Ô\82·\81j</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_http_output</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_internal_encoding</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_language</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý\81i\82½\82¾\82µ\8ew\92è\82µ\82Ä\82à\89½\82à\95Ï\82í\82ç\82È\82¢\81j</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_output_handler</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_parse_str</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_preferred_mime_name</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_regex_encoding</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_regex_set_options</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_send_mail</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_split</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\95s\89Â\94\</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strcut</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strimwidth</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strlen</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strpos</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strrpos</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strtolower</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\89Â\94\\82¾\82¯\82Ç\91å\95Ï\82»\82¤</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strtoupper</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\89Â\94\\82¾\82¯\82Ç\91å\95Ï\82»\82¤</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_strwidth</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_substitute_character</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\93ï\82µ\82»\82¤</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_substr_count</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
- <TR>
- <TD>
- <P><FONT FACE="Times New Roman, serif"><SPAN LANG="en-US">mb_substr</SPAN></FONT></P>
- </TD>
- <TD>
- <P>\83T\83|\81[\83g\8dÏ\82Ý</P>
- </TD>
- </TR>
-</TABLE>
-<P><BR><BR>
-</P>
-</BODY>
-</HTML>
\ No newline at end of file
+<html>
+<head>
+
+ <meta http-equiv="CONTENT-TYPE" content="text/html; charset=shift_jis">
+ <title>\95Ï\8dX\97\9a\97ð</title>
+
+
+ <meta name="GENERATOR" content="OpenOffice.org 1.1.3 (Win32)">
+
+ <meta name="CREATED" content="20050130;2310982">
+
+ <meta name="CHANGED" content="20050130;2372139">
+
+</head>
+
+
+<body style="direction: ltr;" lang="ja-JP">
+
+<h2>\95Ï\8dX\97\9a\97ð</h2>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">mbstring\83G\83~\83\85\83\8c\81[\83^ for Japanese Ver.0.84</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2006/1/23</span></font>\81j</h3>
+
+<ul>
+
+ <li>\83V\83t\83gJIS\82Å\94¼\8ap\83J\83\93\83}\82Ì\8f\88\97\9d\82ª\82¨\82©\82µ\82©\82Á\82½\82Ì\82ð\8fC\90³\82µ\82Ü\82µ\82½</li>
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">mbstring\83G\83~\83\85\83\8c\81[\83^ for Japanese Ver.0.83</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2005/12/15</span></font>\81j</h3>
+
+<ul>
+
+ <li>mb_send_mail\82Åmb_language\82ªja\82¾\82Á\82½\82Æ\82«\82É\91Î\89\9e\82µ\82Ü\82µ\82½</li>
+ <li>mb_send_mail\82Å\93ú\96{\8cê\8f\88\97\9d\82Ì\8dÅ\8cã\82Ébreak\82ª\82È\82©\82Á\82½\82Ì\82Å\89Á\82¦\82Ü\82µ\82½</li>
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">mbstring\83G\83~\83\85\83\8c\81[\83^ for Japanese Ver.0.82</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2005/11/28</span></font>\81j</h3>
+
+<ul>
+
+ <li>mb_language\82Å\83p\83\89\83\81\81[\83^\82ª\82È\82©\82Á\82½\8fê\8d\87\82Éwarning\82ª\8fo\82Ä\82µ\82Ü\82¤\82Ì\82ð\8fC\90³\82µ\82Ü\82µ\82½</li>
+ <li>mb_send_mail\93à\95\94\82Å_is_encoded\82ð\8cÄ\82Ñ\8fo\82µ\82Ä\82¢\82é\82Ì\82ð_check_encoding\82ð\8cÄ\82Ô\82æ\82¤\82É\8fC\90³\82µ\82Ü\82µ\82½</li>
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">mbstring\83G\83~\83\85\83\8c\81[\83^ for Japanese Ver.0.81</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2005/10/09</span></font>\81j</h3>
+
+<ul>
+
+ <li>$jis_match\82ª\96¢\92è\8b`\82¾\82Á\82½\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½</li>
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">mbstring\83G\83~\83\85\83\8c\81[\83^ for Japanese Ver.0.8</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2005/8/23</span></font>\81j</h3>
+
+<ul>
+
+ <li>\96¼\8fÌ\82ðmbstring\83G\83~\83\85\83\8c\81[\83^ for Japanese\82É\95Ï\8dX\82µ\82Ü\82µ\82½</li>
+ <li>
+mb_substitute_character\83T\83|\81[\83g\82µ\82Ü\82µ\82½
+ </li>
+
+ <li>
+mb_convert_case\83T\83|\81[\83g\82µ\82Ü\82µ\82½
+ </li>
+
+ <li>
+mb_get_info\83T\83|\81[\83g\82µ\82Ü\82µ\82½
+ </li>
+
+ <li>
+mb_strtolower\83T\83|\81[\83g\82µ\82Ü\82µ\82½
+ </li>
+
+ <li>
+mb_strtoupper\83T\83|\81[\83g\82µ\82Ü\82µ\82½</li>
+ <li>MB_CASE_UPPER\81CMB_CASE_LOWER\81CMB_CASE_CASE\82ð\92è\8b`\82µ\82Ü\82µ\82½</li>
+
+ <li>\83O\83\8d\81[\83o\83\8b\95Ï\90\94\82ð$mbemu_internals\82É\8fW\96ñ\82µ\82Ü\82µ\82½</li>
+
+ <li>\83G\83\93\83R\81[\83f\83B\83\93\83O\82ÉSHIFT_JIS\81CISO-8859-1\82ð\92Ç\89Á\82µ\82Ü\82µ\82½</li>
+
+ <li>\95Ï\8a·\83e\81[\83u\83\8b\82ð\95K\97v\8e\9e\82É\93Ç\82Ý\8d\9e\82Þ\82æ\82¤\82É\8fC\90³\82µ\82Ü\82µ\82½</li>
+ <li>
+ mb_convert_kana\82Ì\83G\83\93\83R\81[\83f\83B\83\93\83O\82ª\8ew\92è\82³\82ê\82Ä\82¢\82È\82¢\82Æ\82«\81Cinternal_encoding\82Ì\92l\82ð\8eg\82¤\82æ\82¤\82É\8fC\90³\82µ\82Ü\82µ\82½</li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.37</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2005/1/30</span></font>\81j</h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">JIS</span></font>\82Ì\83}\83b\83`\83\93\83O\82Ì\83o\83O\82ð\8dÄ\82Ñ\8fC\90³\82µ\82Ü\82µ\82½\81B
+ </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.36</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2004/11/13</span></font>\81j</h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">JIS</span></font>\82Ì\83}\83b\83`\83\93\83O\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.35</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2004/9/26</span></font>\81j</h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_send_mail</span></font>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ
+\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.341</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2004/9/16</span></font>\81j</h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_kana</span></font>\82Ì\83o\83O\82ð\8fC\90³\82µ
+\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.34</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2004/9/15</span></font>\81j</h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_kana</span></font>\82Ì\83o\83O\82ð\8fC\90³\82µ
+\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.33</span></font>\81i<font face="Times New Roman, serif"><span lang="en-US">2004/8/27</span></font>\81j</h3>
+
+<ul>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">mb_encode_numericentity,
+mb_decode_numericentity</span></font>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">mb_convert_encoding</span></font>\82Å<font face="Times New Roman, serif"><span lang="en-US">UTF-16</span></font>\82©
+\82ç\82Ì\95Ï\8a·\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;">\83V\83t\83g<font face="Times New Roman, serif"><span lang="en-US">JIS</span></font>\82Ì
+\8f\88\97\9d\82ð<font face="Times New Roman, serif"><span lang="en-US">SJIS-WIN</span></font>\8cÝ\8a·\82É\82µ\82Ü\82µ\82½\81B<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+mbstring</span></font>\96{\89Æ\82Æ\82Í\88Ù\82È\82è\81C<font face="Times New Roman, serif"><span lang="en-US">SJIS</span></font>\82Æ<font face="Times New Roman, serif"><span lang="en-US">SJIS-WIN</span></font>\82Ì
+\93®\8dì\82Í\93¯\82¶\82Å\82·\81B </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">mb_strcut</span></font>\82Ì
+\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+ <li>
+ <p>\95Ï\8dX\97\9a\97ð\82ð<font face="Times New Roman, serif"><span lang="en-US">HTML</span></font>\82É\95Ï\82¦\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.32(2004/8/19)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_http_input, mb_http_output,
+mb_output_handler </span></font>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+ </span></font>\82½\82¾\82µ\81C<font face="Times New Roman, serif"><span lang="en-US">mb_http_input</span></font>\82É\8aÖ\82µ\82Ä\82Í\95¶\8e\9a\83R\81[
+\83h\95Ï\8a·\82ð\8ds\82í\82È\82¢\82½\82ß\81C\8fí\82É<font face="Times New Roman, serif"><span lang="en-US">FALSE</span></font>\82ð\95Ô\82µ\82Ü\82·\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.31(2004/8/16)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">mb_decode_mimeheader</span></font>\82Ì
+\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½ </p>
+
+ </li>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_variables</span></font>\82Ì\8f\89
+\8aú\90Ý\92è\83`\83F\83b\83N\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½ </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.3(2004/8/8)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p style="margin-bottom: 0cm;">\83o\83O\82Â\82Ô\82µ<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+ </span></font>\93ü\82ê\8eq\82Ì\83t\83@\83\93\83N\83V\83\87\83\93\82Å\93ñ\8fd\90é\8c¾\82É\82È\82Á\82Ä\82µ\82Ü\82¤\8fê\8d\87\82ª\82 \82é\82Ì\82Å\8aO\95\94\82É\8fo\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;">\83o\83O\82Â\82Ô\82µ<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+mb_strcut</span></font>\82Ì\83o\83O\82ð\8fC\90³\82µ\82Ü\82µ\82½ </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">mb_encode_mimeheader,
+mb_decode_mimeheader</span></font>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_variables</span></font>\82Å\94z
+\97ñ\82©\82ç\82Ì\95Ï\8a·\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+ </span></font>\82±\82ê\82É\94º\82¢<font face="Times New Roman, serif"><span lang="en-US">mb_convert_variables</span></font>\82ð<font face="Times New Roman, serif"><span lang="en-US">2</span></font>\83p
+\83^\81[\83\93\82É\82µ\81C\8f\89\8aú\90Ý\92è\82Å\95Ï\8dX\82Å\82«\82é\82æ\82¤\82É\82µ\82Ü\82µ\82½\81B<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+ </span></font>\8f\89\8aú\90Ý\92è\83t\83@\83C\83\8b\82Ì<font face="Times New Roman, serif"><span lang="en-US">convert-variables-arrayonly</span></font>\82ª<font face="Times New Roman, serif"><span lang="en-US">no</span></font>\82Ì
+\8fê\8d\87\81i\83f\83t\83H\83\8b\83g\81j\81C\82±\82ê\82Ü\82Å\82Æ\93¯\82¶\82æ\82¤\82É\94z\97ñ\82Å\82È\82\82Ä\82à\95Ï\8a·\82µ\82Ü\82·\81B\82Ü\82½\81C\8dÅ\8f\89\82Ì\97v\91f\82ª\94z\97ñ\82Ì\8fê\8d\87\81C\82»\82ê\82¾\82¯\82ð\95Ï\8a·\82µ\82Ü\82·\81B\82½\82¾\82µ\81C\82±\82¿\82ç\82Ì\8fê\8d\87\81C\8cÄ\82Ñ
+\8fo\82µ\8e\9e\82É\88ø\90\94\82É<font face="Times New Roman, serif"><span lang="en-US">&</span></font>\82ð\95t\82¯\82Ä\96¾\8e¦\93I\82É\8eQ\8fÆ\93n\82µ\82É
+\82·\82é\95K\97v\82ª\82 \82è\82Ü\82·\81B<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+convert-variables-arrayonly</span></font>\82ª<font face="Times New Roman, serif"><span lang="en-US">no</span></font>\82Å
+\82È\82¢\8fê\8d\87\81C\95Ï\8a·\82·\82é\88ø\90\94\82Í\94z\97ñ\82¾\82¯\82É\82È\82è\82Ü\82·\81B\82»\82Ì\91ã\82í\82è\81C<font face="Times New Roman, serif"><span lang="en-US">&</span></font>\82Í\95s\97v\82Å\82·\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">Ver.0.25(2004/7/7)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p>\83o\83O\82Â\82Ô\82µ<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+ </span></font>\93ü\82ê\8eq\82Ì\83t\83@\83\93\83N\83V\83\87\83\93\82Å\93ñ\8fd\90é\8c¾\82É\82È\82Á\82Ä\82µ\82Ü\82¤\8fê\8d\87\82ª\82 \82é\82Ì\82Å\8aO\95\94\82É\8fo\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">ver.0.24(2004/6/8)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strpos, mb_substr_count,
+mb_preferred_mime_name</span></font>\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">ver.0.23(2004/5/19)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_encoding</span></font>\82Å<font face="Times New Roman, serif"><span lang="en-US">UTF-16</span></font>\82Ö
+\82Ì\95Ï\8a·\82ð\83T\83|\81[\83g\82µ\82Ü\82µ\82½\81B<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+ <br>
+
+usage:<br>
+
+$str = mb_convert_encoding($str, 'UTF-16', 'EUC-JP, UTF-8');<br>
+
+ <br>
+
+ </span></font>\95Ô\82·\82Ì\82Í<font face="Times New Roman, serif"><span lang="en-US">BOM</span></font>\82È\82µ\82Ì\83r\83b\83O\81E\83G\83\93\83f\83B\83A\83\93\82É\82È\82è\82Ü\82·\81B
+ </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">ver.0.22(2004/5/11)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p style="margin-bottom: 0cm;">\83o\83O\82Â\82Ô\82µ </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">mb_convert_variables</span></font>\82ð
+\8eb\92è\83T\83|\81[\83g </p>
+
+ </li>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strwidth</span></font>\82ð\83T\83|\81[\83g </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">ver.0.21(2004/4/28)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p style="margin-bottom: 0cm;">\8f\89\8aú\90Ý\92è\82ð<font face="Times New Roman, serif"><span lang="en-US">mb-emulator.ini</span></font>\82©
+\82ç\93Ç\82Þ\82æ\82¤\82É\95Ï\8dX </p>
+
+ </li>
+
+ <li>
+ <p style="margin-bottom: 0cm;"><font face="Times New Roman, serif"><span lang="en-US">EUC</span></font>\82Æ<font face="Times New Roman, serif"><span lang="en-US">UTF-8</span></font>\8aÔ
+\82ð\92¼\90Ú\95Ï\8a·\82·\82é\82æ\82¤\82É\95Ï\8dX </p>
+
+ </li>
+
+ <li>
+ <p>\83o\83O\82Â\82Ô\82µ </p>
+
+ </li>
+
+</ul>
+
+<h3><font face="Times New Roman, serif"><span lang="en-US">ver.0.2(2004/4/27)</span></font></h3>
+
+<ul>
+
+ <li>
+ <p><font face="Times New Roman, serif"><span lang="en-US">jcode</span></font>\82ð\8eg\82í\82È\82¢\8c`\82Å\93Æ\97§\82µ\82Ü\82µ\82½\81B<font face="Times New Roman, serif"><span lang="en-US">12</span></font>\8aÖ
+\90\94\83T\83|\81[\83g<font face="Times New Roman, serif"><span lang="en-US"><br>
+
+mb_language, mb_internal_encoding, mb_convert_encoding,
+mb_convert_kana, mb_send_mail, mb_strimwidth, mb_detect_encoding,
+mb_detect_order, mb_strlen, mb_substr, mb_strcut, mb_strrpos </span></font>
+ </p>
+
+ </li>
+
+</ul>
+
+<h2>\8aÖ\90\94\83T\83|\81[\83g\8fó\8bµ\81i<font face="Times New Roman, serif"><span lang="en-US">2004/8/19</span></font>\81j</h2>
+
+<table cellpadding="2" cellspacing="2">
+
+ <tbody>
+
+ <tr>
+
+ <td width="150">
+ <p><font face="Times New Roman, serif"><span lang="en-US"><b>mbstring</b></span></font><b>\8aÖ
+\90\94\96¼</b></p>
+
+ </td>
+
+ <td width="300">
+ <p><b>\8d¡\8cã\82Ì\83T\83|\81[\83g\97\\92è</b></p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_case</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\89Â\94\\82¾\82¯\82Ç\8c\8b\8d\\91å\95Ï\82»\82¤\81B\82 \82Ü\82è\8eg\82¢\82»\82¤\82É\82È\82¢\8bC\82ª\82·\82é\81B\82à\82µ\83j\81[\83Y\82ª\82 \82ê\82Î</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_encoding</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_kana</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_convert_variables</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_decode_mimeheader</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_decode_numericentity</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_detect_encoding</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_detect_order</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_encode_mimeheader</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_encode_numericentity</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_match</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_replace</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search_getpos</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search_getregs</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search_init</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search_pos</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search_regs</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search_setpos</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg_search</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_ereg</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_eregi_replace</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_eregi</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_get_info</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_http_input</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý\81i\8fí\82É<font face="Times New Roman, serif"><span lang="en-US">FALSE</span></font>\82ð\95Ô\82·\81j</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_http_output</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_internal_encoding</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_language</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý\81i\82½\82¾\82µ\8ew\92è\82µ\82Ä\82à\89½\82à\95Ï\82í\82ç\82È\82¢\81j</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_output_handler</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_parse_str</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_preferred_mime_name</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_regex_encoding</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_regex_set_options</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_send_mail</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_split</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\95s\89Â\94\</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strcut</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strimwidth</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strlen</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strpos</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strrpos</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strtolower</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\89Â\94\\82¾\82¯\82Ç\91å\95Ï\82»\82¤</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strtoupper</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\89Â\94\\82¾\82¯\82Ç\91å\95Ï\82»\82¤</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_strwidth</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_substitute_character</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\93ï\82µ\82»\82¤</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_substr_count</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ <tr>
+
+ <td>
+ <p><font face="Times New Roman, serif"><span lang="en-US">mb_substr</span></font></p>
+
+ </td>
+
+ <td>
+ <p>\83T\83|\81[\83g\8dÏ\82Ý</p>
+
+ </td>
+
+ </tr>
+
+ </tbody>
+</table>
+
+<p><br>
+
+<br>
+
+</p>
+
+</body>
+</html>
<?php
-/* mb-emulator.php by Andy
+/* mbstring emulator for Japanese by Andy
* email : webmaster@matsubarafamily.com
*
* license based on GPL(GNU General Public License)
*
- * Ver.0.37 (2005/1/30)
+ * Ver.0.84 (2006/1/20)
*/
+define('MB_CASE_UPPER', 0);
+define('MB_CASE_LOWER', 1);
+define('MB_CASE_TITLE', 2);
include dirname(__FILE__).'/convert.table';
-include dirname(__FILE__).'/sjistouni.table';
-include dirname(__FILE__).'/unitosjis.table';
+// include dirname(__FILE__).'/sjistouni.table';
+// include dirname(__FILE__).'/unitosjis.table';
-$ini_file = parse_ini_file(dirname(__FILE__).'/mb-emulator.ini');
-$_language = $ini_file['language'];
-$_internal_encoding = $ini_file['internal_encoding'];
-$_lang_array = array (
- 'Japanese', 'ja', 'English', 'en', 'uni'
+$mbemu_internals['ini_file'] = parse_ini_file(dirname(__FILE__).'/mb-emulator.ini');
+
+$mbemu_internals['language'] = $mbemu_internals['ini_file']['language'];
+$mbemu_internals['internal_encoding'] = $mbemu_internals['ini_file']['internal_encoding'];
+$mbemu_internals['lang_array'] = array (
+ 'Japanese', 'ja','jp', 'English', 'en', 'uni'
);
-$_mb_encoding = array (
- 'AUTO' => 0,
+$mbemu_internals['encoding'] = array (
+ 'AUTO' => 0xFF,
'ASCII' => 0,
'EUC-JP' => 1,
'EUC' => 1,
'SJIS' => 2,
'SHIFT-JIS' => 2,
+ 'SHIFT_JIS' => 2,
'SJIS-WIN' => 2,
'JIS' => 3,
'ISO-2022-JP' => 3,
'UTF-8' => 4,
'UTF8' => 4,
- 'UTF-16'=>5
+ 'UTF-16'=>5,
+ 'ISO-8859-1' => 6
);
-if (!(mb_detect_order($ini_file['detect_order'])))
- $_detect_order = array ("ASCII", "JIS", "UTF-8", "EUC-JP", "SJIS");
+function mb_detect_order($encoding_list = '')
+{
+ global $mbemu_internals;
+
+ if ($encoding_list) {
+ if (is_string($encoding_list)) {
+ $encoding_list = strtoupper($encoding_list);
+ $encoding_list = split(', *', $encoding_list);
+ }
+ foreach($encoding_list as $encode)
+ if (!array_key_exists($encode, $mbemu_internals['encoding'])) return FALSE;
+ $mbemu_internals['detect_order'] = $encoding_list;
+ return TRUE;
+ }
+ return $mbemu_internals['detect_order'];
+}
+
+if (!(mb_detect_order($mbemu_internals['ini_file']['detect_order'])))
+ $mbemu_internals['detect_order'] = array ("ASCII", "JIS", "UTF-8", "EUC-JP", "SJIS");
+
+$mbemu_internals['substitute_character'] = $mbemu_internals['ini_file']['substitute_character'];
+
+$mbemu_internals['regex'] = array(
+ 0 => "[\x01-\x7F]", // for ASCII
+ 1 => "[\xA1-\xFE]([\xA1-\xFE])|[\x01-\x7F]|\x8E([\xA0-\xDF])", // for EUC-JP
+ 2 => "[\x81-\x9F\xE0-\xFC]([\x40-\xFC])|[\x01-\x7F]|[\xA0-\xDF]", // for Shift_JIS
+ 3 => "(?:^|\x1B\(\x42)([\x01-\x1A,\x1C-\x7F]*)|(?:\x1B\\$\x42([\x01-\x1A,\x1C-\x7F]*))|(?:\x1B\(I([\x01-\x1A,\x1C-\x7F]*))", // for JIS
+ 4 => "[\x01-\x7F]|[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF][\x80-\xBF]", // for UTF-8
+ 5 => "..", // for UTF-16
+ 6 => "." // for ISO-8859-1
+ );
-$sjis_match = "[\x81-\x9F,\xE0-\xFC]([\x40-\xFC])|[\x01-\x7F]|[\xA0-\xDF]";
-$euc_match = "[\xa1-\xfe]([\xa1-\xfe])|[\x01-\x7f]|\x8e([\xa0-\xdf])";
-$utf8_match = "[\x01-\x7F]|[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF][\x80-\xBF]";
-$jis_match = "(?:^|\x1b\(\x42)([^\x1b]*)|(?:\x1b\\$\x42([^\x1b]*))|(?:\x1b\(I([^\x1b]*))";
-function mb_language($language)
+function mb_language($language='')
{
- global $_language, $_lang_array;
+ global $mbemu_internals;
if ($language =='') {
- if ($_language == '') return FALSE;
- else return $_language;
+ if ($mbemu_internals['language'] == '') return FALSE;
+ else return $mbemu_internals['language'];
} else {
- foreach ($_lang_array as $element) {
+ foreach ($mbemu_internals['lang_array'] as $element) {
if ($element == $language) {
- $_language = $language;
+ $mbemu_internals['language'] = $language;
return TRUE;
}
}
function mb_internal_encoding($encoding = '')
{
- global $_internal_encoding;
+ global $mbemu_internals;
if ($encoding =='') {
- if ($_internal_encoding == '') return FALSE;
- else return $_internal_encoding;
+ if ($mbemu_internals['internal_encoding'] == '') return FALSE;
+ else return $mbemu_internals['internal_encoding'];
} else {
- $_internal_encoding = $encoding;
+ $mbemu_internals['internal_encoding'] = $encoding;
return TRUE;
}
}
+function mb_get_info($type = 'all')
+{
+ switch(strtolower($type)) {
+ case 'all' :
+ $a['internal_encoding'] = mb_internal_encoding();
+ $a['http_output'] = mb_http_output();
+ $a['http_input'] = 'pass';
+ $a['func_overload'] = 'pass';
+ return $a;
+ case 'internal_encoding' :
+ return mb_internal_encoding();
+ case 'http_output' :
+ return mb_http_output();
+ case 'http_input' :
+ return 'pass';
+ case 'func_overloard' :
+ return 'pass';
+ }
+}
+
+function mb_substitute_character($subchar='')
+{
+ global $mbemu_internals;
+
+ if (!$subchar) return $mbemu_internals['substitute_character'];
+ if (is_int($subchar)) {
+ $mbemu_internals['substitute_character'] = $subchar;
+ } else {
+ $subchar = strtolower($subchar);
+ switch ($subchar) {
+ case 'none' :
+ case 'long' :
+ $mbemu_internals['substitute_character'] = $subchar;
+ }
+ }
+}
function mb_convert_encoding( $str, $to_encoding, $from_encoding = '')
{
- global $_internal_encoding, $_mb_encoding;
+ global $mbemu_internals;
$to_encoding = strtoupper($to_encoding);
$from_encoding = mb_detect_encoding($str, $from_encoding);
- switch ($_mb_encoding[$from_encoding]) {
+ switch ($mbemu_internals['encoding'][$from_encoding]) {
case 1: //euc-jp
- switch($_mb_encoding[$to_encoding]) {
+ switch($mbemu_internals['encoding'][$to_encoding]) {
case 2: //sjis
return _euctosjis($str);
case 3: //jis
return $str;
}
case 2: //sjis
- switch($_mb_encoding[$to_encoding]) {
+ switch($mbemu_internals['encoding'][$to_encoding]) {
case 1: //euc-jp
return _sjistoeuc($str);
case 3: //jis
return $str;
}
case 3: //jis
- switch($_mb_encoding[$to_encoding]) {
+ switch($mbemu_internals['encoding'][$to_encoding]) {
case 1: //euc-jp
$str = _jistosjis($str);
return _sjistoeuc($str);
return $str;
}
case 4: //utf8
- switch($_mb_encoding[$to_encoding]) {
+ switch($mbemu_internals['encoding'][$to_encoding]) {
case 1: //euc-jp
return _utf8toeuc($str);
case 2: //sjis
}
case 5: //utf16
$str = _utf16toutf8($str);
- switch($_mb_encoding[$to_encoding]) {
+ switch($mbemu_internals['encoding'][$to_encoding]) {
case 1: //euc-jp
return _utf8toeuc($str);
case 2: //sjis
}
}
-function _get_encoding(&$str, $encoding)
-{
- global $_internal_encoding, $_mb_encoding;
-
- if ($encoding =='') {
- if ($_internal_encoding == '') {
- return mb_detect_encoding($str, mb_detect_order());
- } else {
- return $_internal_encoding;
- }
- }
- return strtoupper($encoding);
-}
-
function _sjistoeuc(&$str)
{
- global $sjis_match, $_sjistoeuc_byte1, $_sjistoeuc_byte2, $_sjistoeuc_byte1_shift;
+ global $mbemu_internals;
- $max = preg_match_all("/$sjis_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
$str_EUC = '';
for ($i = 0; $i < $max; ++$i) {
$num = ord($allchars[0][$i]); // \8ae\95¶\8e\9a\82Ì1\83o\83C\83g\96Ú\82ð\90\94\92l\82Æ\82µ\82Ä\8eæ\82è\8fo\82·
if ($num2 = ord($allchars[1][$i])) { // 2\83o\83C\83g\96Ú\82ª\82 \82é\8fê\8d\87
- $shift = $_sjistoeuc_byte1_shift[$num2];
- $str_EUC .= chr($_sjistoeuc_byte1[$num] + $shift)
- .chr($_sjistoeuc_byte2[$shift][$num2]);
+ $shift = $mbemu_internals['sjistoeuc_byte1_shift'][$num2];
+ $str_EUC .= chr($mbemu_internals['sjistoeuc_byte1'][$num] + $shift)
+ .chr($mbemu_internals['sjistoeuc_byte2'][$shift][$num2]);
} elseif ($num <= 0x7F) {//\89p\90\94\8e\9a
$str_EUC .= chr($num);
} else { //\94¼\8ap\83J\83i
function _euctosjis(&$str)
{
- global $euc_match, $_euctosjis_byte1, $_euctosjis_byte2;
- $max = preg_match_all("/$euc_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ global $mbemu_internals;
+ $max = preg_match_all('/'.$mbemu_internals['regex'][1].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
$str_SJIS = '';
for ($i = 0; $i < $max; ++$i) {
$num = ord($allchars[0][$i]); // \8ae\95¶\8e\9a\82Ì1\83o\83C\83g\96Ú\82ð\90\94\92l\82Æ\82µ\82Ä\8eæ\82è\8fo\82·
if ($num2 = ord($allchars[1][$i])) { // \8a¿\8e\9a\82Ì\8fê\8d\87
- $str_SJIS .= chr($_euctosjis_byte1[$num]);
+ $str_SJIS .= chr($mbemu_internals['euctosjis_byte1'][$num]);
if ($num & 1)
- $str_SJIS .= chr($_euctosjis_byte2[0][$num2]);
+ $str_SJIS .= chr($mbemu_internals['euctosjis_byte2'][0][$num2]);
else
- $str_SJIS .= chr($_euctosjis_byte2[1][$num2]);
+ $str_SJIS .= chr($mbemu_internals['euctosjis_byte2'][1][$num2]);
} elseif ($num3 = ord($allchars[2][$i])) {//\94¼\8ap\83J\83i
$str_SJIS .= chr($num3);
} else { //\89p\90\94\8e\9a
function _sjistojis(&$str)
{
- global $sjis_match, $_sjistoeuc_byte1, $_sjistoeuc_byte2, $_sjistoeuc_byte1_shift;
+ global $mbemu_internals;
- $max = preg_match_all("/$sjis_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
$str_JIS = '';
$mode = 0; // \89p\90\94
for ($i = 0; $i < $max; ++$i) {
$mode = 1;
$str_JIS .= chr(0x1b).'$B';
}
- $shift = $_sjistoeuc_byte1_shift[$num2];
- $str_JIS .= chr(($_sjistoeuc_byte1[$num] + $shift) & 0x7F)
- .chr($_sjistoeuc_byte2[$shift][$num2] & 0x7F);
+ $shift = $mbemu_internals['sjistoeuc_byte1_shift'][$num2];
+ $str_JIS .= chr(($mbemu_internals['sjistoeuc_byte1'][$num] + $shift) & 0x7F)
+ .chr($mbemu_internals['sjistoeuc_byte2'][$shift][$num2] & 0x7F);
} elseif ($num > 0x80) {//\94¼\8ap\83J\83i
if ($mode != 2) {
$mode = 2;
function _sub_jtosj($match)
{
- global $_euctosjis_byte1, $_euctosjis_byte2;
+ global $mbemu_internals;
$num = ord($match[0]);
$num2 = ord($match[1]);
- $s = chr($_euctosjis_byte1[$num | 0x80]);
+ $s = chr($mbemu_internals['euctosjis_byte1'][$num | 0x80]);
if ($num & 1) {
- $s .= chr($_euctosjis_byte2[0][$num2 | 0x80]);
+ $s .= chr($mbemu_internals['euctosjis_byte2'][0][$num2 | 0x80]);
} else {
- $s .= chr($_euctosjis_byte2[1][$num2 | 0x80]);
+ $s .= chr($mbemu_internals['euctosjis_byte2'][1][$num2 | 0x80]);
}
return $s;
}
function _jistosjis(&$str)
{
- global $_euctosjis_byte1, $_euctosjis_byte2, $jis_match;
+ global $mbemu_internals;
- $max = preg_match_all("/$jis_match/", $str, $allchunks, PREG_SET_ORDER); // \95¶\8e\9a\8eí\82²\82Æ\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][3].'/', $str, $allchunks, PREG_SET_ORDER); // \95¶\8e\9a\8eí\82²\82Æ\82Ì\94z\97ñ\82É\95ª\89ð
$st = '';
for ($i = 0; $i < $max; ++$i) {
if (ord($allchunks[$i][1])) { //\89p\90\94\82É\83}\83b\83`
function _sjistoutf8(&$str)
{
-
- global $sjis_match, $sjistoucs2;
+ global $mbemu_internals;
+ include_once(dirname(__FILE__).'/sjistouni.table');
$st = '';
- $max = preg_match_all("/$sjis_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
for ($i = 0; $i < $max; ++$i) {
$num = ord($allchars[0][$i]); // \8ae\95¶\8e\9a\82Ì1\83o\83C\83g\96Ú\82ð\90\94\92l\82Æ\82µ\82Ä\8eæ\82è\8fo\82·
if ($num2 = ord($allchars[1][$i])) { // 2\83o\83C\83g\96Ú\82ª\82 \82é\8fê\8d\87
- $ucs2 = $sjistoucs2[($num << 8) | $num2];
+ $ucs2 = $mbemu_internals['sjistoucs2'][($num << 8) | $num2];
$st .= _ucs2utf8($ucs2);
} elseif ($num > 0x80) {//\94¼\8ap\83J\83i
$st .= _ucs2utf8(0xfec0 + $num);
function _utf8tosjis(&$str)
{
- global $utf8_match, $ucs2tosjis;
+ global $mbemu_internals;
+ include_once(dirname(__FILE__).'/unitosjis.table');
$st = '';
- $max = preg_match_all("/$utf8_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
for ($i = 0; $i < $max; ++$i) {
$num = _utf8ucs2($allchars[0][$i]); //ucs2\82Ì\92l\82ð\8eæ\82è\8fo\82·
if ($num < 0x80)
elseif ((0xff61 <= $num) && ($num <= 0xff9f))
$st .= chr($num - 0xfec0);
else {
- $sjis = $ucs2tosjis[$num];
+ $sjis = $mbemu_internals['ucs2tosjis'][$num];
$st .= chr($sjis >> 8) . chr($sjis & 0xff);
}
}
function _euctoutf8(&$str)
{
- global $euc_match, $sjistoucs2, $_euctosjis_byte1, $_euctosjis_byte2;
+ global $mbemu_internals;
+ include_once(dirname(__FILE__).'/sjistouni.table');
$st = '';
- $max = preg_match_all("/$euc_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][1].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
for ($i = 0; $i < $max; ++$i) {
$num = ord($allchars[0][$i]); // \8ae\95¶\8e\9a\82Ì1\83o\83C\83g\96Ú\82ð\90\94\92l\82Æ\82µ\82Ä\8eæ\82è\8fo\82·
if ($num2 = ord($allchars[1][$i])) { // 2\83o\83C\83g\96Ú\82ª\82 \82é\8fê\8d\87
if ($num & 1)
- $sjis = ($_euctosjis_byte1[$num] << 8) | $_euctosjis_byte2[0][$num2];
+ $sjis = ($mbemu_internals['euctosjis_byte1'][$num] << 8) | $mbemu_internals['euctosjis_byte2'][0][$num2];
else
- $sjis = ($_euctosjis_byte1[$num] << 8) | $_euctosjis_byte2[1][$num2];
- $st .= _ucs2utf8($sjistoucs2[$sjis]);
+ $sjis = ($mbemu_internals['euctosjis_byte1'][$num] << 8) | $mbemu_internals['euctosjis_byte2'][1][$num2];
+ $st .= _ucs2utf8($mbemu_internals['sjistoucs2'][$sjis]);
} elseif ($num3 = ord($allchars[2][$i])) {
$st .= _ucs2utf8(0xfec0 + $num3);
} else {//\94¼\8ap\89p\90\94
function _utf8toeuc(&$str)
{
- global $utf8_match, $ucs2tosjis, $_sjistoeuc_byte1, $_sjistoeuc_byte2, $_sjistoeuc_byte1_shift;
+ global $mbemu_internals;
+ include_once(dirname(__FILE__).'/unitosjis.table');
$st = '';
- $max = preg_match_all("/$utf8_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
for ($i = 0; $i < $max; ++$i) {
$num = _utf8ucs2($allchars[0][$i]); //ucs2\82Ì\92l\82ð\8eæ\82è\8fo\82·
if ($num < 0x80)
elseif ((0xff61 <= $num) && ($num <= 0xff9f)) //\94¼\8ap\83J\83i
$st .= chr(0x8e) . chr($num - 0xfec0);
else {
- $sjis = $ucs2tosjis[$num];
+ $sjis = $mbemu_internals['ucs2tosjis'][$num];
$upper = $sjis >> 8;
$lower = $sjis & 0xff;
- $shift = $_sjistoeuc_byte1_shift[$lower];
- $st .= chr($_sjistoeuc_byte1[$upper] + $shift)
- .chr($_sjistoeuc_byte2[$shift][$lower]);
+ $shift = $mbemu_internals['sjistoeuc_byte1_shift'][$lower];
+ $st .= chr($mbemu_internals['sjistoeuc_byte1'][$upper] + $shift)
+ .chr($mbemu_internals['sjistoeuc_byte2'][$shift][$lower]);
}
}
return $st;
function _utf8toutf16(&$str)
{
- global $utf8_match;
+ global $mbemu_internals;
$st = '';
- $max = preg_match_all("/$utf8_match/", $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $allchars); // \95¶\8e\9a\82Ì\94z\97ñ\82É\95ª\89ð
for ($i = 0; $i < $max; ++$i) {
$num = _utf8ucs2($allchars[0][$i]); //ucs2\82Ì\92l\82ð\8eæ\82è\8fo\82·
$st .= chr(($num >> 8) & 0xff).chr($num & 0xff);
function _utf16toutf8(&$str)
{
- global $utf8_match;
+ global $mbemu_internals;
$st = '';
$ar = unpack("n*", $str);
foreach($ar as $char) {
function sub_zenhan_EUC(&$str, $match) {
- global $alphanumeric_convert;
+ global $mbemu_internals;
$match = $match . "|[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e[\xa0-\xdf]";
$max = preg_match_all("/$match/", $str, $chars);
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($num = ord($chars[1][$i])) //\91S\8ap\82É\83}\83b\83`\83\93\83O\82µ\82½\8fê\8d\87
- $str .= chr(array_search($chars[1][$i], $alphanumeric_convert));
+ $str .= chr(array_search($chars[1][$i], $mbemu_internals['alphanumeric_convert']));
// $str .= chr($num & 0x7F);
else
$str .= $chars[0][$i];
}
function sub_hanzen_EUC(&$str, $match) {
- global $alphanumeric_convert;
+ global $mbemu_internals;
$match = $match . "|[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e[\xa0-\xdf]";
$max = preg_match_all("/$match/", $str, $chars);
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($num = ord($chars[1][$i])) //\94¼\8ap\82É\83}\83b\83`\83\93\83O\82µ\82½\8fê\8d\87
- $str .= $alphanumeric_convert[$num];
+ $str .= $mbemu_internals['alphanumeric_convert'][$num];
else
$str .= $chars[0][$i];
}
}
function katakana_zenhan_EUC(&$str) {
-global $kana_zenhan_convert, $special_zenhan_convert;
+ global $mbemu_internals;
$match = "\xa5([\xa1-\xf4])|\xa1([\xa2,\xa3,\xa6,\xab,\xac,\xbc,\xd6,\xd7])|[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e[\xa0-\xdf]";
$max = preg_match_all("/$match/", $str, $chars);
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($num = ord($chars[1][$i])) //\83J\83i\82É\83}\83b\83`\83\93\83O\82µ\82½\8fê\8d\87
- $str .= chr(0x8e) . $kana_zenhan_convert[$num];
+ $str .= chr(0x8e) . $mbemu_internals['kana_zenhan_convert'][$num];
elseif ($num = ord($chars[2][$i])) //\94¼\8ap\95Ï\8a·\89Â\94\\82È\93Á\8eê\95¶\8e\9a\82É\83}\83b\83`\82µ\82½\8fê\8d\87
- $str .= chr(0x8e) . $special_zenhan_convert[$num];
+ $str .= chr(0x8e) . $mbemu_internals['special_zenhan_convert'][$num];
else
$str .= $chars[0][$i];
}
}
function hiragana_zenhan_EUC(&$str) {
-global $kana_zenhan_convert, $special_zenhan_convert;
+ global $mbemu_internals;
$match = "\xa4([\xa1-\xf4])|\xa1([\xa2,\xa3,\xa6,\xab,\xac,\xbc,\xd6,\xd7])|[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e[\xa0-\xdf]";
$max = preg_match_all("/$match/", $str, $chars);
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($num = ord($chars[1][$i])) //\82©\82È\82É\83}\83b\83`\83\93\83O\82µ\82½\8fê\8d\87
- $str .= chr(0x8e) . $kana_zenhan_convert[$num];
+ $str .= chr(0x8e) . $mbemu_internals['kana_zenhan_convert'][$num];
elseif ($num = ord($chars[2][$i])) //\94¼\8ap\95Ï\8a·\89Â\94\\82È\93Á\8eê\95¶\8e\9a\82É\83}\83b\83`\82µ\82½\8fê\8d\87
- $str .= chr(0x8e) . $special_zenhan_convert[$num];
+ $str .= chr(0x8e) . $mbemu_internals['special_zenhan_convert'][$num];
else
$str .= $chars[0][$i];
}
}
function katakana_hanzen1_EUC(&$str) { //\91÷\93_\82Ì\93\9d\8d\87\82ð\82·\82é\95û
-global $kana_zenhan_convert, $special_zenhan_convert;
+ global $mbemu_internals;
$match = "\x8e((?:[\xb3,\xb6-\xc4,\xca-\xce]\x8e\xde)|(?:[\xca-\xce]\x8e\xdf))|[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e([\xa1-\xdf])";
//\91÷\93_\82â\94¼\91÷\93_\82Í\88ê\8f\8f\82É\83}\83b\83`\83\93\83O
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($chars[1][$i]) //\91÷\89¹\81C\94¼\91÷\89¹\82É\83}\83b\83`\83\93\83O\82µ\82½\8fê\8d\87
- $str .= chr(0xa5).chr(array_search($chars[1][$i], $kana_zenhan_convert));
+ $str .= chr(0xa5).chr(array_search($chars[1][$i], $mbemu_internals['kana_zenhan_convert']));
elseif ($chars[2][$i]) //\82»\82Ì\91¼\82Ì\94¼\8ap\83J\83i\82É\83}\83b\83`
- if ($num = array_search($chars[2][$i], $kana_zenhan_convert))
+ if ($num = array_search($chars[2][$i], $mbemu_internals['kana_zenhan_convert']))
$str .= chr(0xa5).chr($num);
else
- $str .= chr(0xa1).chr(array_search($chars[2][$i], $special_zenhan_convert));
+ $str .= chr(0xa1).chr(array_search($chars[2][$i], $mbemu_internals['special_zenhan_convert']));
else
$str .= $chars[0][$i];
}
}
function hiragana_hanzen1_EUC(&$str) { //\91÷\93_\82Ì\93\9d\8d\87\82ð\82·\82é\95û
-global $kana_zenhan_convert, $special_zenhan_convert;
+ global $mbemu_internals;
$match = "\x8e((?:[\xb6-\xc4,\xca-\xce]\x8e\xde)|(?:[\xca-\xce]\x8e\xdf))|[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e([\xa1-\xdf])";
//\91÷\93_\82â\94¼\91÷\93_\82Í\88ê\8f\8f\82É\83}\83b\83`\83\93\83O
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($chars[1][$i]) //\91÷\89¹\81C\94¼\91÷\89¹\82É\83}\83b\83`\83\93\83O\82µ\82½\8fê\8d\87
- $str .= chr(0xa4).chr(array_search($chars[1][$i], $kana_zenhan_convert));
+ $str .= chr(0xa4).chr(array_search($chars[1][$i], $mbemu_internals['kana_zenhan_convert']));
elseif ($chars[2][$i]) //\82»\82Ì\91¼\82Ì\94¼\8ap\83J\83i\82É\83}\83b\83`
- if ($num = array_search($chars[2][$i], $kana_zenhan_convert))
+ if ($num = array_search($chars[2][$i], $mbemu_internals['kana_zenhan_convert']))
$str .= chr(0xa4).chr($num);
else
- $str .= chr(0xa1).chr(array_search($chars[2][$i], $special_zenhan_convert));
+ $str .= chr(0xa1).chr(array_search($chars[2][$i], $mbemu_internals['special_zenhan_convert']));
else
$str .= $chars[0][$i];
}
}
function katakana_hanzen2_EUC(&$str) { //\91÷\93_\82Ì\93\9d\8d\87\82ð\82µ\82È\82¢\95û
-global $kana_zenhan_convert, $special_zenhan_convert;
+ global $mbemu_internals;
$match = "[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e([\xa1-\xdf])";
$max = preg_match_all("/$match/", $str, $chars);
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($chars[1][$i]) //\94¼\8ap\83J\83i\82É\83}\83b\83`
- if ($num = array_search($chars[1][$i], $kana_zenhan_convert))
+ if ($num = array_search($chars[1][$i], $mbemu_internals['kana_zenhan_convert']))
$str .= chr(0xa5).chr($num);
else
- $str .= chr(0xa1).chr(array_search($chars[1][$i], $special_zenhan_convert));
+ $str .= chr(0xa1).chr(array_search($chars[1][$i], $mbemu_internals['special_zenhan_convert']));
else
$str .= $chars[0][$i];
}
}
function hiragana_hanzen2_EUC(&$str) { //\91÷\93_\82Ì\93\9d\8d\87\82ð\82µ\82È\82¢\95û
-global $kana_zenhan_convert, $special_zenhan_convert;
+ global $mbemu_internals;
$match = "[\xa1-\xfe][\xa1-\xfe]|[\x01-\x7f]|\x8e([\xa1-\xdf])";
$max = preg_match_all("/$match/", $str, $chars);
$str = '';
for ($i = 0; $i < $max; ++$i) {
if ($chars[1][$i]) //\94¼\8ap\83J\83i\82É\83}\83b\83`
- if ($num = array_search($chars[1][$i], $kana_zenhan_convert))
+ if ($num = array_search($chars[1][$i], $mbemu_internals['kana_zenhan_convert']))
$str .= chr(0xa4).chr($num);
else
- $str .= chr(0xa1).chr(array_search($chars[1][$i], $special_zenhan_convert));
+ $str .= chr(0xa1).chr(array_search($chars[1][$i], $mbemu_internals['special_zenhan_convert']));
else
$str .= $chars[0][$i];
}
function mb_convert_kana( $str, $option='KV', $encoding = '')
{
- $encoding = mb_detect_encoding($str, $encoding);
+ if (!$encoding) $encoding = mb_internal_encoding();
$str = mb_convert_encoding($str, 'EUC-JP', $encoding);
if (strstr($option, "r")) alpha_zenhan_EUC($str);
return $str;
}
-function mb_send_mail($to, $subject, $message , $additional_headers, $additional_parameter)
+// if mb_language is uni this function send mail using UTF-8/Base64
+// if English or en this function send mail using ISO-8859-1/quoted printable
+// if Japanese this function send mail using ISO-2022-JP
+function mb_send_mail($to, $subject, $message , $additional_headers='', $additional_parameter='')
{
- if (!_is_JIS($subject))
- $subject =mb_encode_mimeheader($subject);
- else {
- $tmp = mb_internal_encoding();
- mb_internal_encoding('iso-2022-jp');
- $subject =mb_encode_mimeheader($subject);
- mb_internal_encoding($tmp);
- }
- if (!_is_JIS($message))
- $message = mb_convert_encoding($message, "iso-2022-jp", mb_internal_encoding());
- $additional_headers .=
- "\r\nMime-Version: 1.0\r\nContent-Type: text/plain; charset=ISO-2022-JP\r\nContent-Transfer-Encoding: 7bit";
- mail($to, $subject, $message, $additional_headers, $additional_parameter);
-
-}
-
-
-function mb_detect_order($encoding_list = '')
-{
- global $_detect_order, $_mb_encoding;
-
- if ($encoding_list) {
- if (is_string($encoding_list)) {
- $encoding_list = strtoupper($encoding_list);
- $encoding_list = split(', *', $encoding_list);
- }
- foreach($encoding_list as $encode)
- if (!array_key_exists($encode, $_mb_encoding)) return FALSE;
- $_detect_order = $encoding_list;
- return TRUE;
+ switch (mb_language()) {
+ case 'jp' :
+ case 'ja' :
+ case 'Japanese' :
+ if (!_check_encoding($subject, 3)) //if not JIS encoded
+ $subject =mb_encode_mimeheader($subject);
+ else {
+ $tmp = mb_internal_encoding();
+ mb_internal_encoding('iso-2022-jp');
+ $subject =mb_encode_mimeheader($subject);
+ mb_internal_encoding($tmp);
+ }
+ if (!_check_encoding($message, 3))
+ $message = mb_convert_encoding($message, "iso-2022-jp", mb_internal_encoding());
+ $additional_headers .=
+ "\r\nMime-Version: 1.0\r\nContent-Type: text/plain; charset=ISO-2022-JP\r\nContent-Transfer-Encoding: 7bit";
+ mail($to, $subject, $message, $additional_headers, $additional_parameter);
+ break;
+ case 'en' :
+ case 'English' :
+ $subject =mb_encode_mimeheader($subject, mb_internal_encoding(), 'Q');
+ $message = _sub_encode_base64($message, mb_internal_encoding(), 76 , "\r\n");
+ $additional_headers .=
+ "\r\nMime-Version: 1.0\r\nContent-Type: text/plain; charset=".
+ mb_preferred_mime_name(mb_internal_encoding()).
+ "\r\nContent-Transfer-Encoding: BASE64";
+ mail($to, $subject, $message, $additional_headers, $additional_parameter);
+ break;
+ case 'uni' :
+ $subject =mb_encode_mimeheader($subject, mb_internal_encoding(), 'B');
+ $message = _sub_encode_base64($message, mb_internal_encoding(), 76 , "\r\n");
+ $additional_headers .=
+ "\r\nMime-Version: 1.0\r\nContent-Type: text/plain; charset=".
+ mb_preferred_mime_name(mb_internal_encoding()).
+ "\r\nContent-Transfer-Encoding: BASE64";
+ mail($to, $subject, $message, $additional_headers, $additional_parameter);
+ break;
}
- return $_detect_order;
-}
-
-function _is_Ascii(&$str)
-{
- return (!ereg("[\x80-\xFF]", $str) && !ereg("\x1B", $str));
-}
-
-function _is_JIS(&$str)
-{
- return (!ereg("[\x80-\xFF]", $str) && ereg("\x1B", $str));
+
}
-function _is_SJIS(&$str)
-{
- $sjis_match =
- "[\x01-\x7F]|[\xA0-\xDF]|[\x81-\xFC][\x40-\xFC]";
- return (preg_match("/^($sjis_match)+$/", $str) == 1);
-}
-function _is_EUCJP(&$str)
-{
- $euc_match =
- "[\x01-\x7F]|\x8E[\xA0-\xDF]|\x8F[xA1-\xFE][\xA1-\xFE]|[\xA1-\xFE][\xA1-\xFE]";
- return (preg_match("/^($euc_match)+$/", $str) == 1);
-}
-function _is_UTF8(&$str)
+function _check_encoding($str, $encoding_number)
{
- $utf8_match =
- "[\x01-\x7F]|[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF][\x80-\xBF]";
- return (preg_match("/^($utf8_match)+$/", $str) == 1);
+ global $mbemu_internals;
+ return (preg_match('/^('.$mbemu_internals['regex'][$encoding_number].')+$/', $str) == 1);
}
function mb_detect_encoding( $str , $encoding_list = '')
{
- global $_mb_encoding;
+ global $mbemu_internals;
if ($encoding_list == '')
$encoding_list = mb_detect_order();
}
}
foreach($encoding_list as $encode) {
- switch ($_mb_encoding[$encode]) {
- case 0 : //ascii
- if (_is_ASCII($str)) return 'ASCII';
- break;
- case 1 : //euc-jp
- if (_is_EUCJP($str)) return 'EUC-JP';
- break;
- case 2 : //shift-jis
- if (_is_SJIS($str)) return 'SJIS';
- break;
- case 3 : //jis
- if (_is_JIS($str)) return 'JIS';
- break;
- case 4 : //utf-8
- if (_is_UTF8($str)) return 'UTF-8';
- break;
- }
+ if (_check_encoding($str, $mbemu_internals['encoding'][$encode]))
+ return $encode;
}
return $encode;
}
function mb_strlen ( $str , $encoding='')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($str, $encoding);
+ $encoding = mb_detect_encoding($str, $encoding);
- switch ($_mb_encoding[$encoding]) {
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 1 : //euc-jp
- return preg_match_all("/$euc_match/", $str, $arr);
- case 0 : //ascii
- case 4 : //utf-8
- return preg_match_all("/$utf8_match/", $str, $arr);
case 2 : //shift-jis
- return preg_match_all("/$sjis_match/", $str, $arr);
+ case 4 : //utf-8
+ return preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $arr);
+ case 5 : //utf-16
+ return strlen($str) >> 1;
+ case 0 : //ascii
+ case 6 : //iso8859-1
+ return strlen($str);
case 3 : //jis
$str = mb_convert_encoding($str, 'SJIS', 'JIS');
- return preg_match_all("/$sjis_match/", $str, $arr);
+ return preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $arr);
}
}
function mb_strwidth( $str, $encoding='')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($str, $encoding);
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- $max = $len = preg_match_all("/$euc_match/", $str, $arr);
- $len;
- for ($i=0; $i < $max; ++$i)
- if ($arr[1][$i]) ++$len;
- return $len;
- case 0 : //ascii
+ $encoding = mb_detect_encoding($str, $encoding);
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 4 : //utf-8
- $max = $len = preg_match_all("/$utf8_match/", $str, $arr);
+ $max = $len = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $arr);
for ($i=0; $i < $max; ++$i) {
$ucs2 = _utf8ucs2($arr[0][$i]);
if (((0x2000 <= $ucs2) && ($ucs2 <= 0xff60)) || (0xffa0 <= $ucs2))
++$len;
}
return $len;
+ case 1 : //euc-jp
case 2 : //shift-jis
- $max = $len = preg_match_all("/$sjis_match/", $str, $arr);
+ $max = $len = preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $arr);
for ($i=0; $i < $max; ++$i)
if ($arr[1][$i]) ++$len;
return $len;
+ case 5 : //utf-16
+ $max = $len = preg_match_all('/'.$mbemu_internals['regex'][5].'/', $str, $arr);
+ for ($i=0; $i < $max; ++$i) {
+ $ucs2 = (ord($arr[0][$i]) << 8) | ord(substr($arr[0][$i],1,1));
+ if (((0x2000 <= $ucs2) && ($ucs2 <= 0xff60)) || (0xffa0 <= $ucs2))
+ ++$len;
+ }
+ return $len;
+ case 0 : //ascii
+ case 6 : //iso8859-1
+ return strlen($str);
case 3 : //jis
$str = mb_convert_encoding($str, 'SJIS', 'JIS');
- $max = $len = preg_match_all("/$sjis_match/", $str, $arr);
+ $max = $len = preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $arr);
for ($i=0; $i < $max; ++$i)
if ($arr[1][$i]) ++$len;
return $len;
function mb_strimwidth( $str, $start, $width, $trimmarker , $encoding = '')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($str, $encoding);
+ $encoding = mb_detect_encoding($str, $encoding);
$str = mb_substr($str, $start, 'notnumber', $encoding);
if (($len = mb_strwidth($str,$encoding)) <= $width)
return $str;
$width -= $trimwidth;
if ($width <= 0) return $trimmarker;
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- preg_match_all("/$euc_match/", $str, $arr);
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
+ case 0 : //ascii
+ case 6 : //iso8859-1
+ return substr($str, 0, $width).$trimmarker;
+ case 4 : //utf-8
+ preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $arr);
$i = 0;
while(TRUE) {
- if ($arr[1][$i])
+ $ucs2 = _utf8ucs2($arr[0][$i]);
+ if (((0x2000 <= $ucs2) && ($ucs2 <= 0xff60)) || (0xffa0 <= $ucs2))
$width -= 2;
else
--$width;
}
$arr[0] = array_slice($arr[0], 0, $i);
return implode("", $arr[0]).$trimmarker;
- case 0 : //ascii
- case 4 : //utf-8
- preg_match_all("/$utf8_match/", $str, $arr);
+ case 5 : //utf-16
+ $arr = unpack("n*", $str);
$i = 0;
- while(TRUE) {
- $ucs2 = _utf8ucs2($arr[0][$i]);
+ foreach($arr as $ucs2) {
if (((0x2000 <= $ucs2) && ($ucs2 <= 0xff60)) || (0xffa0 <= $ucs2))
$width -= 2;
else
}
$arr[0] = array_slice($arr[0], 0, $i);
return implode("", $arr[0]).$trimmarker;
+ case 1 : //euc-jp
case 2 : //shift-jis
- preg_match_all("/$sjis_match/", $str, $arr);
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $arr);
$i = 0;
while(TRUE) {
if ($arr[1][$i])
case 3 : //jis
$str = mb_convert_encoding($str, 'SJIS', 'JIS');
$trimmarker = mb_convert_encoding($trimmarker, 'SJIS', 'JIS');
- preg_match_all("/$sjis_match/", $str, $arr);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $arr);
$i = 0;
while(TRUE) {
if ($arr[1][$i])
function mb_substr ( $str, $start , $length='notnumber' , $encoding='')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($str, $encoding);
+ $encoding = mb_detect_encoding($str, $encoding);
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- preg_match_all("/$euc_match/", $str, $arr);
- break;
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
- case 4 : //utf-8
- preg_match_all("/$utf8_match/", $str, $arr);
- break;
+ case 1 : //euc-jp
case 2 : //shift-jis
- preg_match_all("/$sjis_match/", $str, $arr);
+ case 4 : //utf-8
+ case 5 : //utf-16
+ case 6 : //iso-8859-1
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $arr);
break;
case 3 : //jis
$str = mb_convert_encoding($str, 'SJIS', 'JIS');
- preg_match_all("/$sjis_match/", $str, $arr);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $arr);
}
if (is_int($length))
$arr[0] = array_slice($arr[0], $start, $length);
else
$arr[0] = array_slice($arr[0], $start);
$str = implode("", $arr[0]);
- if ($_mb_encoding[$encoding] == 3)
+ if ($mbemu_internals['encoding'][$encoding] == 3)
$str = mb_convert_encoding($str, 'JIS', 'SJIS');
return $str;
}
function mb_strcut ( $str, $start , $length=0 , $encoding = '')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
-
- $encoding = _get_encoding($str, $encoding);
+ $encoding = mb_detect_encoding($str, $encoding);
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- preg_match_all("/$euc_match/", $str, $arr);
- return _sub_strcut($arr, $start, $length);
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
- return substr($str, $start, $length);
- case 4 : //utf-8
- preg_match_all("/$utf8_match/", $str, $arr);
- return _sub_strcut($arr, $start, $length);
+ case 1 : //euc-jp
case 2 : //shift-jis
- preg_match_all("/$sjis_match/", $str, $arr);
+ case 4 : //utf-8
+ case 5 : //utf-16
+ case 6 : //iso-8859-1
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $arr);
return _sub_strcut($arr, $start, $length);
case 3 : //jis
$str = mb_convert_encoding($str, 'SJIS', 'JIS');
- preg_match_all("/$sjis_match/", $str, $arr);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $str, $arr);
$sub = _sub_strcut($arr, $start, $length);
return mb_convert_encoding($sub, 'JIS', 'SJIS');
}
function mb_strrpos ( $haystack, $needle , $encoding = '')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($haystack, $encoding);
+ $encoding = mb_detect_encoding($haystack, $encoding);
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- preg_match_all("/$euc_match/", $haystack, $ar_h);
- preg_match_all("/$euc_match/", $needle, $ar_n);
- return _sub_strrpos($ar_h[0], $ar_n[0]);
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
- case 4 : //utf-8
- preg_match_all("/$utf8_match/", $haystack, $ar_h);
- preg_match_all("/$utf8_match/", $needle, $ar_n);
- return _sub_strrpos($ar_h[0], $ar_n[0]);
+ case 1 : //euc-jp
case 2 : //shift-jis
- preg_match_all("/$sjis_match/", $haystack, $ar_h);
- preg_match_all("/$sjis_match/", $needle, $ar_n);
+ case 4 : //utf-8
+ case 5 : //utf-16
+ case 6 : //iso-8859-1
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $haystack, $ar_h);
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $needle, $ar_n);
return _sub_strrpos($ar_h[0], $ar_n[0]);
case 3 : //jis
$haystack = mb_convert_encoding($haystack, 'SJIS', 'JIS');
$needle = mb_convert_encoding($needle, 'SJIS', 'JIS');
- preg_match_all("/$sjis_match/", $haystack, $ar_h);
- preg_match_all("/$sjis_match/", $needle, $ar_n);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $haystack, $ar_h);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $needle, $ar_n);
return _sub_strrpos($ar_h[0], $ar_n[0]);
}
}
function mb_strpos ( $haystack, $needle , $offset = 0, $encoding = '')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($haystack, $encoding);
+ $encoding = mb_detect_encoding($haystack, $encoding);
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- preg_match_all("/$euc_match/", $haystack, $ar_h);
- preg_match_all("/$euc_match/", $needle, $ar_n);
- return _sub_strpos($ar_h[0], $ar_n[0], $offset);
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
- case 4 : //utf-8
- preg_match_all("/$utf8_match/", $haystack, $ar_h);
- preg_match_all("/$utf8_match/", $needle, $ar_n);
- return _sub_strpos($ar_h[0], $ar_n[0], $offset);
+ case 1 : //euc-jp
case 2 : //shift-jis
- preg_match_all("/$sjis_match/", $haystack, $ar_h);
- preg_match_all("/$sjis_match/", $needle, $ar_n);
+ case 4 : //utf-8
+ case 5 : //utf-16
+ case 6 : //iso-8859-1
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $haystack, $ar_h);
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $needle, $ar_n);
return _sub_strpos($ar_h[0], $ar_n[0], $offset);
case 3 : //jis
$haystack = mb_convert_encoding($haystack, 'SJIS', 'JIS');
$needle = mb_convert_encoding($needle, 'SJIS', 'JIS');
- preg_match_all("/$sjis_match/", $haystack, $ar_h);
- preg_match_all("/$sjis_match/", $needle, $ar_n);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $haystack, $ar_h);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $needle, $ar_n);
return _sub_strpos($ar_h[0], $ar_n[0], $offset);
}
}
function mb_substr_count($haystack, $needle , $encoding = '')
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match;
+ global $mbemu_internals;
- $encoding = _get_encoding($haystack, $encoding);
+ $encoding = mb_detect_encoding($haystack, $encoding);
- switch ($_mb_encoding[$encoding]) {
- case 1 : //euc-jp
- preg_match_all("/$euc_match/", $haystack, $ar_h);
- preg_match_all("/$euc_match/", $needle, $ar_n);
- return _sub_substr_count($ar_h[0], $ar_n[0]);
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
- case 4 : //utf-8
- preg_match_all("/$utf8_match/", $haystack, $ar_h);
- preg_match_all("/$utf8_match/", $needle, $ar_n);
- return _sub_substr_count($ar_h[0], $ar_n[0]);
+ case 1 : //euc-jp
case 2 : //shift-jis
- preg_match_all("/$sjis_match/", $haystack, $ar_h);
- preg_match_all("/$sjis_match/", $needle, $ar_n);
+ case 4 : //utf-8
+ case 5 : //utf-16
+ case 6 : //iso-8859-1
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $haystack, $ar_h);
+ preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $needle, $ar_n);
return _sub_substr_count($ar_h[0], $ar_n[0]);
case 3 : //jis
$haystack = mb_convert_encoding($haystack, 'SJIS', 'JIS');
$needle = mb_convert_encoding($needle, 'SJIS', 'JIS');
- preg_match_all("/$sjis_match/", $haystack, $ar_h);
- preg_match_all("/$sjis_match/", $needle, $ar_n);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $haystack, $ar_h);
+ preg_match_all('/'.$mbemu_internals['regex'][2].'/', $needle, $ar_n);
return _sub_substr_count($ar_h[0], $ar_n[0]);
}
}
/******************
mb_convert_variables
*******************/
-if (!$ini_file['convert_variables_arrayonly']) {
+if (!$mbemu_internals['ini_file']['convert_variables_arrayonly']) {
function mb_convert_variables($to_encoding, $from_encoding, $s1, $s2='',$s3='',$s4='',$s5='',$s6='',$s7='', $s8='',$s9='', $s10='')
{
if (is_array($s1)) {
function mb_preferred_mime_name ($encoding)
{
- global $_mb_encoding;
+ global $mbemu_internals;
$encoding = strtoupper($encoding);
- switch ($_mb_encoding[$encoding]) {
+ switch ($mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
return 'US-ASCII';
case 1 : //euc-jp
return 'ISO-2022-JP';
case 4 : //utf-8
return 'UTF-8';
+ case 5 :
+ return 'UTF-16';
+ case 6 :
+ return 'ISO-8859-1';
}
}
function _sub_quoted_printable_encode($str, $encoding, $maxline, $linefeed)
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match, $jis_match;
- switch ($_mb_encoding[$encoding]) {
+ global $mbemu_internals;
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
- $allchars[0] = unpack("c*", $str);
- $max = count($allchars[0]);
- break;
case 1 : //euc-jp
- $max = preg_match_all("/$euc_match/", $str, $allchars);
- break;
case 2 : //shift-jis
- $max = preg_match_all("/$sjis_match/", $str, $allchars);
- break;
case 4 : //utf-8
- $max = preg_match_all("/$utf8_match/", $str, $allchars);
+ $max = preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $allchars);
break;
case 3 : //jis
- $max = preg_match_all("/$jis_match/", $str, $allchunks, PREG_SET_ORDER); // \95¶\8e\9a\8eí\82²\82Æ\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][3].'/', $str, $allchunks, PREG_SET_ORDER); // \95¶\8e\9a\8eí\82²\82Æ\82Ì\94z\97ñ\82É\95ª\89ð
$st = ''; // quoted printable\95Ï\8a·\8cã\82Ì\95¶\8e\9a\97ñ
$len = $maxline; // \82»\82Ì\8ds\82É\92Ç\89Á\89Â\94\\82È\83o\83C\83g\90\94
$needterminate = FALSE; //\8dÅ\8cã\82É\83G\83X\83P\81[\83v\83V\81[\83P\83\93\83X\82ª\95K\97v\82©\82Ç\82¤\82©
function _sub_encode_base64($str, $encoding, $maxline , $linefeed)
{
- global $_mb_encoding, $euc_match, $utf8_match, $sjis_match, $jis_match;
- switch ($_mb_encoding[$encoding]) {
+ global $mbemu_internals;
+ switch ($e = $mbemu_internals['encoding'][$encoding]) {
case 0 : //ascii
+ case 6 : //iso-8859-1
return chunk_split( base64_encode($str) , $maxline, $linefeed);
case 1 : //euc-jp
- $max = preg_match_all("/$euc_match/", $str, $allchars);
- break;
case 2 : //shift-jis
- $max = preg_match_all("/$sjis_match/", $str, $allchars);
- break;
case 4 : //utf-8
- $max = preg_match_all("/$utf8_match/", $str, $allchars);
+ case 5 : //utf-16
+ $max = preg_match_all('/'.$mbemu_internals['regex'][$e].'/', $str, $allchars);
break;
case 3 : //jis
- $max = preg_match_all("/$jis_match/", $str, $allchunks, PREG_SET_ORDER); // \95¶\8e\9a\8eí\82²\82Æ\82Ì\94z\97ñ\82É\95ª\89ð
+ $max = preg_match_all('/'.$mbemu_internals['regex'][3].'/', $str, $allchunks); // \95¶\8e\9a\8eí\82²\82Æ\82Ì\94z\97ñ\82É\95ª\89ð
$st = ''; // BASE64\95Ï\8a·\8cã\82Ì\95¶\8e\9a\97ñ
$maxbytes = floor($maxline * 3 / 4); //1\8ds\82É\95Ï\8a·\89Â\94\\82È\83o\83C\83g\90\94
$len = $maxbytes; // \82»\82Ì\8ds\82É\92Ç\89Á\89Â\94\\82È\83o\83C\83g\90\94
$line = ''; //1\8ds\95ª\82Ì\95Ï\8a·\91O\82Ì\95¶\8e\9a\97ñ
$needterminate = FALSE; //\8dÅ\8cã\82É\83G\83X\83P\81[\83v\83V\81[\83P\83\93\83X\82ª\95K\97v\82©\82Ç\82¤\82©
for ($i = 0; $i < $max; ++$i) {
- if (ord($allchunks[$i][1])) { //\89p\90\94\82É\83}\83b\83`
+ if (ord($allchunks[1][$i])) { //\89p\90\94\82É\83}\83b\83`
if ($needterminate) {
$line .= chr(0x1B).'(B';
$len -= 3;
}
- $tmpstr = $allchunks[$i][1]; //\92Ç\89Á\82·\82é\95¶\8e\9a\97ñ
+ $tmpstr = $allchunks[1][$i]; //\92Ç\89Á\82·\82é\95¶\8e\9a\97ñ
$l = strlen($tmpstr); //\92Ç\89Á\82·\82é\95¶\8e\9a\97ñ\82Ì\92·\82³
while ($l > $len) {
$line .= substr($tmpstr, 0, $len);
$line .= $tmpstr;
$len -= $l;
$needterminate = FALSE;
- } elseif (ord($allchunks[$i][2])) { //\8a¿\8e\9a\82É\83}\83b\83`
- $tmpstr = substr($allchunks[$i][0], 3);
+ } elseif (ord($allchunks[2][$i])) { //\8a¿\8e\9a\82É\83}\83b\83`
+ $tmpstr = substr($allchunks[0][$i], 3);
if ($len < 8) { //\95¶\8e\9a\82ð\92Ç\89Á\82·\82é\82Ì\82É\8dÅ\92á8\83o\83C\83g\95K\97v\82È\82Ì\82Å
if ($needterminate)
$line .= chr(0x1B).'(B';
$len -= $l;
$needterminate = TRUE;
- } elseif (ord($allchunks[$i][3])) { //\94¼\8ap\83J\83i\82É\83}\83b\83`
- $tmpstr = $allchunks[$i][3];
+ } elseif (ord($allchunks[3][$i])) { //\94¼\8ap\83J\83i\82É\83}\83b\83`
+ $tmpstr = $allchunks[3][$i];
if ($len < 7) { //\95¶\8e\9a\82ð\92Ç\89Á\82·\82é\82Ì\82É\8dÅ\92á7\83o\83C\83g\95K\97v\82È\82Ì\82Å
if ($needterminate)
$line .= chr(0x1B).'(B';
function mb_encode_mimeheader( $str, $encoding = "ISO-2022-JP", $transfer_encoding = "B", $linefeed = "\r\n")
{
- global $_mb_encoding;
+ global $mbemu_internals;
if ($transfer_encoding == "b") $transfer_encoding = "B";
if ($transfer_encoding <> "B") $transfer_encoding = "Q";
$encoding = strtoupper($encoding);
function mb_http_output($encoding = '')
{
- global $ini_file;
+ global $mbemu_internals;
- if ($encoding == '') return $ini_file['http_output'];
+ if ($encoding == '') return $mbemu_internals['ini_file']['http_output'];
if (strtolower($encoding) == 'pass') {
- $ini_file['http_output'] = 'pass';
+ $mbemu_internals['ini_file']['http_output'] = 'pass';
return TRUE;
}
- $ini_file['http_output'] = mb_preferred_mime_name($encoding);
+ $mbemu_internals['ini_file']['http_output'] = mb_preferred_mime_name($encoding);
return TRUE;
}
function mb_output_handler ( $buffer, $status='')
{
- global $ini_file, $tmpstr;
- if ($ini_file['http_output'] == 'pass')
+ global $mbemu_internals;
+ if ($mbemu_internals['ini_file']['http_output'] == 'pass')
return $buffer;
- return mb_convert_encoding($buffer, $ini_file['http_output'], mb_internal_encoding());
+ return mb_convert_encoding($buffer, $mbemu_internals['ini_file']['http_output'], mb_internal_encoding());
}
return $s;
}
+function mb_strtoupper($str, $encoding='')
+{
+ global $mbemu_internals;
+
+ include_once(dirname(__FILE__).'/upper.table');
+ $encoding = mb_detect_encoding($str, $encoding);
+ $str = mb_convert_encoding($str, 'UTF-8', $encoding);
+
+ $max = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $allchars); // make array of chars
+ $newst = '';
+ for ($i = 0; $i < $max; ++$i) {
+ $val = _utf8ucs2($allchars[0][$i]); //get ucs2 value
+ if ((0x61 <= $val) && ($val <= 0x7a)) {
+ $val -= 0x20;
+ $newst .= _ucs2utf8($val);
+ } elseif ($upper = $mbemu_internals['upperarray'][$val]) {
+ $newst .= _ucs2utf8($upper);
+ } else {
+ $newst .= $allchars[0][$i];
+ }
+ }
+ return mb_convert_encoding($newst, $encoding, 'UTF-8');
+}
+
+function mb_strtolower($str, $encoding='')
+{
+ global $mbemu_internals;
+
+ include_once(dirname(__FILE__).'/lower.table');
+ $encoding = mb_detect_encoding($str, $encoding);
+ $str = mb_convert_encoding($str, 'UTF-8', $encoding);
+
+ $max = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $allchars); // make array of chars
+ $newst = '';
+ for ($i = 0; $i < $max; ++$i) {
+ $val = _utf8ucs2($allchars[0][$i]); //get ucs2 value
+ if ((0x41 <= $val) && ($val <= 0x5a)) {
+ $val += 0x20;
+ $newst .= _ucs2utf8($val);
+ } elseif ($lower = $mbemu_internals['lowerarray'][$val]) {
+ $newst .= _ucs2utf8($lower);
+ } else {
+ $newst .= $allchars[0][$i];
+ }
+ }
+ return mb_convert_encoding($newst, $encoding, 'UTF-8');
+}
+
+function mb_convert_case($str, $case, $encoding='')
+{
+ global $mbemu_internals;
+
+ switch($case) {
+ case MB_CASE_UPPER :
+ return mb_strtoupper($str, $encoding);
+ case MB_CASE_LOWER :
+ return mb_strtolower($str, $encoding);
+ case MB_CASE_TITLE :
+ include_once(dirname(__FILE__).'/upper.table');
+ include_once(dirname(__FILE__).'/lower.table');
+ $encoding = mb_detect_encoding($str, $encoding);
+ $str = mb_convert_encoding($str, 'UTF-8', $encoding);
+
+ $max = preg_match_all('/'.$mbemu_internals['regex'][4].'/', $str, $allchars); // make array of chars
+ $newst = '';
+ $isalpha = FALSE;
+ for ($i = 0; $i < $max; ++$i) {
+ $val = _utf8ucs2($allchars[0][$i]); //get ucs2 value
+ if ((0x41 <= $val) && ($val <= 0x5a)) {
+ if ($isalpha) {
+ $val += 0x20; // to lower;
+ } else {
+ $isalpha = TRUE;
+ }
+ $newst .= _ucs2utf8($val);
+ } elseif ((0x61 <= $val) && ($val <= 0x7a)){
+ if (!$isalpha) {
+ $val -= 0x20; // to upper
+ $isalpha = TRUE;
+ }
+ $newst .= _ucs2utf8($val);
+ } elseif ($upper = $mbemu_internals['upperarray'][$val]) { // this char is lower
+ if ($isalpha) {
+ $newst .= _ucs2utf8($val);
+ } else {
+ $isalpha = TRUE;
+ $newst .= _ucs2utf8($upper);
+ }
+ } elseif ($lower = $mbemu_internals['lowerarray'][$val]) { // this char is upper
+ if ($isalpha) {
+ $newst .= _ucs2utf8($lower);
+ } else {
+ $isalpha = TRUE;
+ $newst .= _ucs2utf8($val);
+ }
+ } else {
+ $isalpha = FALSE;
+ $newst .= $allchars[0][$i];
+ }
+ }
+ return mb_convert_encoding($newst, $encoding, 'UTF-8');
+ }
+}
+
function _print_str($str) {
$all = unpack("C*", $str);