Listing of charset.sh


#!/bin/bash

m=32			# elements per row
n=$[ 4*1024/$m ]		# total elements printed

echo "Content-type: text/html"
echo ""
echo "<html><head><title>HTML charachter codes</title></head><body>"
echo "<table>"
i=0
while [ $i -lt $n ]
do
  echo "<tr><th>$[ $i * $m ]-$[ $i * $m + $m - 1 ]</th>"
  j=0
  while [ $j -lt $m ]
  do
    k=$[ $i * $m + $j ]
    #echo "<td>&amp;#${k};&nbsp;=&nbsp;'&#${k};'</td>"
    echo "<td>&#${k};</td>"
    j=$[ $j + 1 ]
  done
  echo "</tr>"
  i=$[ $i + 1 ]
done
echo "</table></body></html>"


 frickin' computers Mark Frazer -- mjfrazer@gmail.com  frickin' computers