URL decoding: Difference between revisions

Content deleted Content added
Blanvill (talk | contribs)
→‎{{header|Vlang}}: Rename "Vlang" in "V (Vlang)"
Langurmonkey (talk | contribs)
added langur language example
Line 909:
 
</syntaxhighlight>
 
 
=={{header|langur}}==
This example code works with Unicode, not just ASCII.
<syntaxhighlight lang="langur">val .finish = f(.s) b2s map f toNumber(.x, 16), rest split "%", .s
val .decode = f(.s) replace .s, re/(%[0-9A-Fa-f]{2})+/, .finish
 
writeln .decode("http%3A%2F%2Ffoo%20bar%2F")
writeln .decode("google.com/search?q=%60Abdu%27l-Bah%C3%A1")
</syntaxhighlight>
 
{{out}}
<pre>http://foo bar/
google.com/search?q=`Abdu'l-Bahá
</pre>
 
 
=={{header|Lasso}}==