2006/06/20
urlencode
Tcl版のurlencode
#urlencode #文字コードはUTF-8 proc urlencode {text} { set url "" foreach byte [split [encoding convertto utf-8 $text] ""] { scan $byte %c i if {[string match {[%<>"]} $byte] || $i <= 32 || $i > 127} { append url [format %%%02X $i] } else { append url $byte } } return $url }


![The Wonder of the Above....[EXPLORED] A photo on Flickr](http://farm5.static.flickr.com/4019/4628222516_ea4b184849_s.jpg)



