~ubuntu-branches/debian/sid/libembperl-perl/sid

« back to all changes in this revision

Viewing changes to test/html/callsub.htm

  • Committer: Bazaar Package Importer
  • Author(s): Angus Lees
  • Date: 2004-02-15 14:23:39 UTC
  • Revision ID: james.westby@ubuntu.com-20040215142339-n21gqf7mx9tmyb8d
Tags: upstream-2.0b10
ImportĀ upstreamĀ versionĀ 2.0b10

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<html>
 
2
<head>
 
3
<title>Tests for Embperl - Embperl sub Metacommand</title>
 
4
</head>
 
5
 
 
6
 
 
7
<body>
 
8
 
 
9
[###### first sub #####]
 
10
[$sub txt$]
 
11
*txt* 
 
12
*txt* <h2>Here goes some normal html text <h2>
 
13
*txt* 
 
14
[$endsub$]
 
15
 
 
16
 
 
17
[###### second sub #####]
 
18
[$sub perl_code $]
 
19
*perl_code* 
 
20
*perl_code* Here comes some perl:
 
21
*perl_code* 
 
22
*perl_code* [- $foo = 'Hello world' -]
 
23
*perl_code* 
 
24
*perl_code* foo = [+ $foo +]<br>
 
25
*perl_code* testdata = [+ $testdata +]<br>
 
26
*perl_code* 
 
27
[$endsub$]
 
28
 
 
29
[###### main page #####]
 
30
 
 
31
 
 
32
<h1>Tests for Embperl - Embperl sub Metacommand</h1>
 
33
 
 
34
[- $testdata = 'abcd' -]
 
35
 
 
36
Now we call the first sub via Execute:
 
37
 
 
38
[- Execute ('#txt') -]
 
39
 
 
40
And now the second via Execute:
 
41
 
 
42
[- Execute ('#perl_code') -]
 
43
 
 
44
Now we call the first sub via Perl:
 
45
 
 
46
[- txt -]
 
47
 
 
48
And now the second via Perl:
 
49
 
 
50
[- perl_code -]
 
51
 
 
52
-> Second time, other order:
 
53
 
 
54
And now the second via Perl:
 
55
 
 
56
[- perl_code -]
 
57
 
 
58
Now we call the first sub via Perl:
 
59
 
 
60
[- txt -]
 
61
 
 
62
-> And Execute again, but other order
 
63
 
 
64
And now the second via Execute:
 
65
 
 
66
[- Execute ('#perl_code') -]
 
67
 
 
68
Now we call the first sub via Execute:
 
69
 
 
70
[- Execute ('#txt') -]
 
71
 
 
72
 
 
73
 
 
74
And done!
 
75
 
 
76
 
 
77
 
 
78
</body>
 
79
</html>