sub url_encode {
my $text = shift; 【程序编程相关:在 DataGridColumnStyl】 【推荐阅读:体验下一代微软平台开发Visual St】$text =~ s/([^a-z0-9_.!~*´() -])/sprintf "%%%02x", ord($1)/egi; 【扩展信息:php5中XML-RPC函数的使用】 $text =~ tr/ /+/; return $text; } sub url_decode { my $text = shift; $text =~ tr/\+/ /; $text =~ s/%([a-f0-9][a-f0-9])/chr( hex( $1 ) )/egi; return $text; }function urlencode(plaintext )
{ // the javascript escape and unescape functions do not correspond // with what browsers actually do... var safechars = "0123456789" + // numeric "abcdefghijklmnopqrstuvwxyz" + // alphabetic "abcdefghijklmnopqrstuvwxyz" + ... 下一页