文書の表示以前のリビジョンバックリンク文書の先頭へ この文書は読取専用です。文書のソースを閲覧することは可能ですが、変更はできません。もし変更したい場合は管理者に連絡してください。 ====== ASCIIコード表 ====== <html> <table border="1" cellpadding="4" cellspacing="0" style="font-size: 16px; text-align: center;"> <tr><td bgcolor="aquamarine">下位ビット→<br />↓上位ビット</td> </html> <php> for ($i = 0x00; $i <= 0x0f; $i = $i + 0x01) { printf('<td bgcolor="aquamarine">%02X</td>', $i); } print('</tr>'); for ($i = 0x00; $i <= 0x7f; $i = $i + 0x10) { printf('<tr><td bgcolor="aquamarine">%02X</td>', $i); for ($j = 0x00; $j <= 0x0f; $j = $j + 0x01) { if ($i == 0x00 || $i == 0x10 || ($i == 0x20 && $j == 0x00)) { // 制御文字の表示 printf('<td>&#x%X;</td>', 0x2400 | $i | $j); } else if ($i == 0x70 && $j == 0x0f) { // 制御文字(DEL)の表示 printf('<td>&#x%X;</td>', 0x2421); } else { printf('<td>%c</td>', $j | $i); } } print('</tr>'); } </php> <html> </table> </html> 上記のコード表を生成するPHPコード <code php> <table border="1" cellpadding="4" cellspacing="0" style="font-size: 16px; text-align: center;"> <tr><td bgcolor="aquamarine">下位ビット→<br />↓上位ビット</td> for ($i = 0x00; $i <= 0x0f; $i = $i + 0x01) { printf('<td bgcolor="aquamarine">%02X</td>', $i); } print('</tr>'); for ($i = 0x00; $i <= 0x7f; $i = $i + 0x10) { printf('<tr><td bgcolor="aquamarine">%02X</td>', $i); for ($j = 0x00; $j <= 0x0f; $j = $j + 0x01) { if ($i == 0x00 || $i == 0x10 || ($i == 0x20 && $j == 0x00)) { // 制御文字の表示 printf('<td>&#x%X;</td>', 0x2400 | $i | $j); } else if ($i == 0x70 && $j == 0x0f) { // 制御文字(DEL)の表示 printf('<td>&#x%X;</td>', 0x2421); } else { printf('<td>%c</td>', $j | $i); } } print('</tr>'); } </table> </code> charset/asciiコード表.txt 最終更新: 2019/08/19 07:05by ともやん