HTML-Embperl
view release on metacpan or search on metacpan
test/cmp/escape.htm view on Meta::CPAN
<html>
<head>
<title>Some tests for Embperl escaping</title>
</head>
<body>
Here it starts with some HTML Text<P>
First of all assign a value:
<BR>
Now we have some 'Umlaute':
Now lets look what we are getting from this:<BR>
(this is the value in $a) (this is the value in $a) äöüäöü???<&+ <BR>
What is the EscMode? 3
Now a Url: <A HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521">Here it goes</A>
A Tag 2: <A HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" TARGET="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This is a text ? & + - %21">a2</A>
A Tag 3: <A TARGET="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This is a text ? & + - %21" HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" TARGET="http://localh...
A Tag 4: <A TARGET="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This is a text ? & + - %21" HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521">a4</A>
A Tag 5: <A TARGET="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This is a text ? & + - %21">a5</A>
A Tag 6: <A >a6</A>
A Tag 7: <A HREF="7">x</A>
A Tag 8: <A TARGET=8 HREF="8">x</A>
A Tag 9: <A HREF="9" TARGET="9">x</A>
A Tag 10: <A TARGET="10" HREF="10" TARGET="10">x</A>
A Tag 11: <A HREF="11" >x</A>
^A Tag 12\: <A HREF=(12|\"12\")>x<\/A>
^A Tag 12b\: <A HREF=(12b|\"12b\") >x<\/A>
A Tag 13: <A HREF="abcd%20%3E">x</A>
A Tag 14: <A HREF="abcd%20%3E">x</A>
FRAME: <FRAME SRC="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" name="%20foo">
IFRAME: <IFRAME SRC="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" name="%20foo">
EMBED: <EMBED SRC="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" name="%20foo">
LAYER: <LAYER SRC="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" name="%20foo">
IMG: <IMG SRC="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" name="%20foo">
FORM: <FORM action="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521" name="%20foo">
Hash in A <a href="http://localhost/tests?A=1&B=2">
Array in A <a href="http://localhost/tests?X=9&Y=8&Z=7">
Hash in H <a href="http://localhost/tests?A=1&B=2">
^Array in H \<a href\=\"http\:\/\/localhost\/tests\?(X=9&Y=8&Z=7)|(Z=7&X=9&Y=8)\"\>
^<a href="tst.html\?(par1=1&par2=2)|(par2=2&par1=1)">1</a>
<a href="tst.html?par1=1&par2=2&par3=3">2</a>
<a href="tst.html?par1=1&par2=2">3</a>
<a href="tst.html?par1=1&par2=2&par3=3">4</a>
1
Now lets look what we are getting from this:<BR>
(this is the value in $a) (this is the value in $a) äöüäöü???<&+ <BR>
What is the EscMode? 1
Now a Url: <A HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This is a text ? & + - %21">Here it goes</A>
2
Now lets look what we are getting from this:<BR>
(this%20is%20the%20value%20in%20$a) (this%20is%20the%20value%20in%20$a)%20äöüäöü%3F%3F%3F%3C%26%2B%20%20<BR>
What is the EscMode? 2
Now a Url: <A HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521">Here it goes</A>
0
Now lets look what we are getting from this:<BR>
(this is the value in $a) (this is the value in $a) äöüäöü???<&+ <BR>
What is the EscMode? 0
Now a Url: <A HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This is a text ? & + - %21">Here it goes</A>
3
Now lets look what we are getting from this:<BR>
(this is the value in $a) (this is the value in $a) äöüäöü???<&+ <BR>
What is the EscMode? 3
Now a Url: <A HREF="http://localhost/tests?id=abcdefghijklmnopqrstuvwxyz&text=This%20is%20a%20text%20%3F%20%26%20%2B%20-%20%2521">Here it goes</A>
What is the EscMode? 3
file.html?name=abcd&data=xyz
Now we localy set $escmode:<BR>
(this is the value in $a) äöüäöü???<&+ \<a><BR>
(this is the value in $a) äöüäöü???<&+ <a><BR>
(this%20is%20the%20value%20in%20$a)%20äöüäöü%3F%3F%3F%3C%26%2B%20%20%20%20<a%3E<BR>
(this is the value in $a) äöüäöü???<&+ <a><BR>
(this is the value in $a) äöüäöü???<&+ \<a><BR>
(this is the value in $a) äöüäöü???<&+ \<a><BR>
(this%20is%20the%20value%20in%20$a)%20äöüäöü%3F%3F%3F%3C%26%2B%20%20%20%20\%3Ca%3E<BR>
(this is the value in $a) äöüäöü???<&+ \<a><BR>
Same without local:
(this is the value in $a) äöüäöü???<&+ \<a><BR>
( run in 0.945 second using v1.01-cache-2.11-cpan-71847e10f99 )