Annotation of parser3/src/www/htdocs/index.html, revision 1.379
1.364 parser 1: @main[]
1.378 parser 2: #^ssave[]
1.377 parser 3: #^calendar[]
1.376 parser 4: #^thash[]
1.373 parser 5: #^tdef[]
1.375 parser 6: #^ford[]
1.371 parser 7: #^tif[]
1.379 ! parser 8: ^image[]
1.369 parser 9: #^mail2[]
1.367 parser 10: #^cookie[]
1.365 parser 11: #^response[]
1.364 parser 12: #^regexp2[]
13: #^ttablerem[]
14: #^pcre[]
15: #^regexp[]<hr>
16: #^mail[]
17: #^exec[]
18: #^fori[]
19: #^tconnect[]
1.378 parser 20: ^xslt[]
1.366 parser 21: #^xml[]
1.364 parser 22: #^header[]
23: OK
1.377 parser 24:
1.379 ! parser 25: @syntax[]
! 26: ^a[^b]
! 27:
1.377 parser 28: @ssave[]
29: $abc[abc]
30: ^abc.save[abc]
1.376 parser 31:
32: @calendar[]
33: 2001;11:<br>
34: $week_days[^date:calendar[rus](2001;11)]
35: <pre>
36: ^week_days.menu{^for[wday](0;7){^if($week_days.$wday){$week_days.$wday; ^; ^;} }<br>}
37: </pre>
1.372 parser 38:
1.375 parser 39: @thash[]
40: $table[^table::set{id name age
41: 1 paf 278
42: 2 пиф 234
43: }]
44: $hash[^table.hash[id;^table::set[nameless]{id
45: name}]]
46: $hash.2.id $hash.2.name $hash.2.age
47:
1.372 parser 48: @tdef[]
49: $s[0]
50: if 0=^if($s){}{n}<br>
51: if def 0=^if(def $s){y}{}<br>
52: <hr>
1.371 parser 53:
54: @ford[]
1.374 parser 55: ^for[i](0;5){$i}{($i)}
1.368 parser 56:
1.370 parser 57: @tif[]
58: ^if[def]{y;n}
59:
1.368 parser 60: @image[]
61: $pict[^image::create(400;200)]
1.379 ! parser 62: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
! 63: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-10;$pict.height-10;0+10;360-10;0xff0000)
! 64: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
! 65: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-10;0x0000ff)
! 66: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+10;360-10;0xff0000)
1.368 parser 67: $response:body[^pict.gif[]]
68:
69:
1.366 parser 70:
1.369 parser 71: @mail2[]
1.367 parser 72: ^mail:send[
1.369 parser 73: $.content-type[$.value[text/plain] $.charset[windows-1251]]
74: $.from[Александр Петросян <paf@design.ru>]
1.367 parser 75: $.to[Александр Петросян <paf@design.ru>]
1.369 parser 76: $.subject[проверка]
77: $.body[проверка]
1.367 parser 78: ]
79:
1.366 parser 80: @cookie[]
1.367 parser 81: $env:HTTP_COOKIE<br>
82:
83: #$cookie:переменная[test тест ТЕСТ2]
84: =$cookie:переменная=<br>
85: #$cookie:переменная2[test тест ТЕСТ3]
86: =$cookie:переменная2=<br>
1.365 parser 87:
88: @response[]
89: #^if($form:reload){
90: $response:refresh[$.value[0] $.url[./t.html?uri=$env:SERVER_NAME]]
91: #}
1.364 parser 92:
93: @xslt[]
94: ^xdata[]
1.375 parser 95: ^show-xdoc2[^xdoc.transform[global.xsl;$.param1[123/]]]
1.364 parser 96:
97: @regexp2[]
98: $s[ select]
99: $s[^s.match[^^\s*][]{!}]
100: $s
101:
102: @header[]
103: $response:refresh[
104: $.value[0]
105: $.url[http://design.ru?a=^taint[123]]
106: ]
107:
108: @ttablerem[]
109: $table[^table::load[a.cfg]]
110: ^table.menu{$table.a}
111:
112: @tconnect[]
113: ^connect[mysql://test:test@paf/test?charset=cp1251_koi8&compress=1&timeout=1&named_pipe=1]{
114: $tables[^table::sql{show tables}]
115: #$cols[^tables.columns[]]
116: #$cols.column
117: ^tables.menu{
118: $tables.[Tables_in_test]<br>
119: }
120: }
121:
122: @pcre[]
123: $s[1 2]
124: ^s.match[\s;ig]{!}
125: #^s.match[\d;ig]{!}
126:
127:
128: @regexp[]
129: $s[abcАБВ]
130: ^if(^s.match[б][i]){y}{n}
131:
132: @mail[]
133: #$ORIGINS(1)
134: ^mail:send[
135: $.from[paf@design.ru]
136: $.to[paf@design.ru]
137: $.body[1
138:
139: 2
140:
141:
142: 3]
143: ]
144:
145: @exec[]
1.370 parser 146: $a[^file::exec[fc.exe;;a;b]]
1.364 parser 147: $a.status|$a.stderr<hr>
148:
149: @fori[][i]
150: ^for[i](1;3){... =$i= ...}
151:
152: @xdata[]
153: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
154: $xdoc[^xdoc::load[input.xml]]
155:
156: @xml[]
157: ^xdata[]
158:
159: ^show-xdoc2[$xdoc]<hr>
160: #^show-xnode1[$xdoc]<hr>
161: $people[^xdoc.select[*/man]]
162: #^show1[]
163: ^show-xnodes1[$people]<hr>
164: #^people.0.owner.hren[]
165:
166: ^show-xnode1[^xdoc.select-single[*/man[2]/name];0;1]<hr>
167:
168: by id:
169: ^show-xnode1[^xdoc.getElementById[1];0;1]
170: <hr>
171:
172: @show1[array]
173: ^for[i](0;^array._count[]-1){
174: $x[$array.$i]
175: $x.firstChild.nodeValue:
176: $pattributes[$x.parentNode.attributes]
177: ^if(^pattributes._count[]){
178: $pattributes.id.name=$pattributes.id.nodeValue
179: }
180: <br>
181: }
182:
183: @show-xnodes1[array][i]
184: ^for[i](0;^array._count[]-1){
185: ^show-xnode1[$array.$i;0;1]
186: }
187:
188: @show-xnode1[x;level;single][l]
189: ^if(def $x){
190: ^for[l](0;$level-1){ ^; ^; ^; ^;}
191: ^if($x.nodeType == $xnode:ELEMENT_NODE){
192: <^;$x.nodeName
193: $pairs[$x.attributes]
194: ^if(def $pairs){
195: $names[^pairs._keys[]]
196: ^names.menu{ $names.key="$pairs.[$names.key].nodeValue"}
197: }
198: >^;
199: }{
200: [$x.nodeType]
201: }
202:
203: ^if(def $x.nodeValue){$x.nodeValue}<br>
204: ^show-xnode1[$x.firstChild]($level+1)
205: ^if(!$single){
206: ^show-xnode1[$x.nextSibling]($level)
207: }
208:
209: ^if($x.nodeType == $xnode:ELEMENT_NODE){
210: ^for[l](0;$level-1){ ^; ^; ^; ^;}<^;/$x.nodeName>^;<br>
211: }
212: }
213:
214: @show-xdoc2[xdoc]
215: ^xdoc.save[save.xml;
216: # $.encoding[windows-1251]
217: $.method[xml]
218: ]
219: $file[^xdoc.file[
220: # $.encoding[windows-1251]
221: $.method[html]
222: ]]
223: ^file.save[text;save_file.html]
224: <pre>^taint[^xdoc.string[]]</pre>
225: # $.encoding[windows-1251]
226: # $.method[xml]
227: #]]
E-mail: