| 1 |
|
| 2 |
<html> |
| 3 |
<head> |
| 4 |
<title>Some Plain tests for Embperl</title> |
| 5 |
</head> |
| 6 |
|
| 7 |
<body> |
| 8 |
|
| 9 |
Here it starts with some HTML Text<P> |
| 10 |
|
| 11 |
All values should be undefined: |
| 12 |
|
| 13 |
$a = [+ $a || '' +] <BR> |
| 14 |
$b = [+ $b || '' +] <BR> |
| 15 |
$c = [+ $c || '' +] <BR> |
| 16 |
$d = [+ $d || '' +] <BR> |
| 17 |
$e = [+ $e || '' +] <BR> |
| 18 |
|
| 19 |
|
| 20 |
First of all assign a value: |
| 21 |
[* $a = '(this is the value in $a)' ; *] <BR> |
| 22 |
|
| 23 |
Now we have some 'Umlaute': |
| 24 |
|
| 25 |
|
| 26 |
[* $b = "$a äöü" ; *] |
| 27 |
|
| 28 |
Now lets look what we are getting from this:<BR> |
| 29 |
[+ $a +] [+ $b +]<BR> |
| 30 |
|
| 31 |
And now a and b together: [+ "$a$b" +]<P> |
| 32 |
|
| 33 |
Here we have some HTML tags within the perl code, Embperl will delete them!<BR> |
| 34 |
|
| 35 |
[+ $c = <BR> 6 + 17 <font size="3"> * 3 </font> + 0 +] |
| 36 |
[+ "SELECT * <br> FROM a ORDER BY b USING <; Hi There>" +] |
| 37 |
|
| 38 |
Here we have something which looks like a HTML tag, but does not start with<br> |
| 39 |
a character, Embperl does not change them!<BR> |
| 40 |
|
| 41 |
[+ "SELECT * FROM a ORDER BY b USING <; Hi There>" +] |
| 42 |
|
| 43 |
Embperl will also translate HMTL escapes to the right characters i.e. $a &lt; 6 will get the perl expression $a < 6: <BR> |
| 44 |
|
| 45 |
[* $e = 2 ; *] |
| 46 |
[+ $d = $e < 6 +] |
| 47 |
|
| 48 |
Now they should have a value |
| 49 |
|
| 50 |
$a = [+ $a +] <BR> |
| 51 |
$b = [+ $b +] <BR> |
| 52 |
$c = [+ $c +] <BR> |
| 53 |
$d = [+ $d +] <BR> |
| 54 |
$e = [+ $e +] <BR> |
| 55 |
|
| 56 |
<P>Ok.<P> |
| 57 |
|
| 58 |
|
| 59 |
</body> |
| 60 |
</html> |