Annotation of parser3/src/www/htdocs/index.html, revision 1.496
1.399 parser 1: @main[]
1.496 ! paf 2: ^tcache2[]
1.489 paf 3: #$ORIGINS(1)
1.488 paf 4: #$t[^table::set{a b} ^table::set{c d}]
1.486 paf 5: #^ttaintuntaint[]
1.493 paf 6: #^tappend2[]
1.480 paf 7: #^badvsnprintf[]
1.479 paf 8: #^badoracequoting[]
1.477 paf 9: #^badconstructors[]
1.475 paf 10: #^xloadwrongtable[]
1.476 paf 11: #^xsetwrongtable[]
1.473 paf 12: #^if($form:test){y}{n}
1.472 paf 13: #^tablecolumnerror[]
14: #^roll[]
1.471 paf 15: #^cookie2[]
1.470 paf 16: #^tableset[]
1.469 paf 17: #^math:PI.format{%.30f}
1.462 paf 18: #^xchildren[]
19: #^thashforeach3[]
1.461 paf 20: #^thashforeach2[]
21: #^thashforeach[]
1.458 paf 22: #^thashdelete[]
1.456 paf 23: #^connect[mysql://user:pass@cd.rinet.ru/db]{^void:sql{z} }
1.454 paf 24: #^tappend[]
1.453 paf 25: #^sappend[]
1.452 paf 26: #^eval(10\3)<br>
1.450 paf 27: #^tform[]
1.448 paf 28: #^formattest[]
1.447 paf 29: #^filelist[]
1.443 paf 30: #^connect[mysql://user:pass@host]{ }
1.431 paf 31: #^безнадёжна_попытка_поправить_непоправимое[]
1.493 paf 32: #^tcache[]
1.460 paf 33: #^thashfileexp[]
1.468 paf 34: #^tcounter[]
1.423 parser 35: #^tablehash[]
1.443 paf 36: #j^hashfile[]
1.417 parser 37: #^formclass[]
1.415 parser 38: #^hren[]
1.485 paf 39: #^domedit[]
1.475 paf 40: #^domxslt[]
1.402 parser 41: #^lsplit2[]
1.401 parser 42: #^faceesize[]
1.445 paf 43: #^imageresize[]
1.399 parser 44: #^ifassignhash[]
45: #^tintdefault[]
46: #$response:status[404]
1.390 parser 47: #^ifpasshash[]
1.387 parser 48: #^movedir[]
49: #^replace[]
1.416 parser 50: #^set[]
1.385 parser 51: #^hash[]<hr>
1.384 parser 52: #$t[^methresult[]] ->$t
1.382 parser 53: #^terror[]
1.378 parser 54: #^ssave[]
1.377 parser 55: #^calendar[]
1.376 parser 56: #^thash[]
1.373 parser 57: #^tdef[]
1.375 parser 58: #^ford[]
1.371 parser 59: #^tif[]
1.383 parser 60: #^image[]
1.369 parser 61: #^mail2[]
1.413 parser 62: #^cookie[]
1.365 parser 63: #^response[]
1.364 parser 64: #^regexp2[]
65: #^ttablerem[]
66: #^pcre[]
67: #^regexp[]<hr>
68: #^mail[]
69: #^exec[]
70: #^fori[]
1.468 paf 71: #^tconnect[]
1.495 paf 72: #^xslt[]
1.470 paf 73: #^xml[]
1.364 parser 74: #^header[]
1.477 paf 75: <hr>
1.364 parser 76: OK
1.495 paf 77:
1.496 ! paf 78: @tcache2[]
! 79: ^cache[$DB_HOME/keyключ](2){
! 80: ^math:random(100)
! 81: }
1.485 paf 82:
1.486 paf 83: @ttaintuntaint[]
84: <!-- некий панковский заголовок с буковкой C в круглых скобках -->^taint[html][
85:
86: ]zz
87: <hr>
88: ^untaint[html]{1^taint[ ]2 3}
89:
90:
1.485 paf 91: @tappend2[]
92: $t[^table::set{a b}]^t.append{1 2}$t.a
1.477 paf 93:
1.479 paf 94: @badvsnprintf[]
95: ^connect[zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz]{
96: }
97:
98:
1.477 paf 99: @badoracequoting[]
100: $SQL.connect-string[oracle://webspb:webpwd@mts?NLS_LANG=RUSSIAN_AMERICA.CL8MSWIN1251&NLS_DATE_FORMAT=YYYY-MM-DD HH24:MI:SS]
101: ^connect[$SQL.connect-string]{
1.478 paf 102: ^void:sql{delete from paf}
1.479 paf 103: ^void:sql{insert into paf values (1, '$form:text')}
1.478 paf 104: $paf[^table::sql{select * from paf}]
105: ^paf.menu{
1.479 paf 106: $paf.id: ^untaint{$paf.block}<hr>
1.478 paf 107:
1.477 paf 108: }
1.478 paf 109: <hr>
110:
1.477 paf 111:
1.478 paf 112: ^rem{
1.477 paf 113: $news[^table::sql{select description from news}[$.limit(3)]]
114: ^news.menu{
115: ^untaint{$news.description}<hr>
116:
117: }
1.478 paf 118: <hr>
119: }
120:
121: $tables[^table::sql{select table_name from user_tables}]
122: ^tables.menu{
123: $tables.table_name<br>
124: }
125:
1.477 paf 126: }
127: <hr>
128: $env:PATH
1.476 paf 129:
130: @badconstructors[]
131: $bred[^string::length[]]
132: $bred[^response::clear[]]
133: $bred[^int::int[]]
134:
1.475 paf 135:
136: @xloadwrongtable[]
137: $constr[^xdoc::load[wrongtable.xml]]
138:
139: @xsetwrongtable[]
140: $constr[^xdoc::set{<?xml version="1.0" encoding="windows-1251z" ?>
141: <block-list>^untaint[as-is]{$constructor}</block-list>}]
142:
1.471 paf 143:
1.472 paf 144: @tablecolumnerror[]
145: $t[^table::set{a}]
146: $t.$a
147:
1.471 paf 148: @roll[]
1.472 paf 149: #$date[^date::set(1970;1;2)]
150: #^date.roll[month](-1)
151: $date[^date::set(2038;1;1)]
1.471 paf 152: ^date.roll[month](+1)
153: $date.year $date.month $date.day
1.470 paf 154:
155: @cookie2[]
156: #=$cookie:clientType[$.value[test]]=<br>
157: =$cookie:clientType=<br>
158:
1.469 paf 159:
160: @tableset[]
161: $a[^table::set{a
162: 1
163: 2}]
164: ^eval(100\$a)
165:
166:
167:
168: @zzz[]
169:
1.462 paf 170:
171: $constructor[
172: <block1 name="main_srvr" type="0" label="Основное тело" />
173: <block2 name="main_srvr2" type="0" label="Основное тело" />
174: ]
175:
176: $constr[^xdoc::set{<?xml version="1.0" encoding="windows-1251" ?>
177: <block-list>^untaint[as-is]{$constructor}</block-list>}]
178:
179: $children[$constr.documentElement.childNodes]
180: ^if($children){
181: ^for[i](1;^children._count[]){
182: $node[$children.$i]
183: $node.nodeName<br>
184: }
185: }
186:
1.461 paf 187:
188: @thashforeach3[]
189: $h[
190: $.a[1]
191: $.b[2]
192: ]
193: $c[^table::set{a
194: ^h.foreach[key;value]{$value
195: }}]
196: $c.a
197:
198: @thashforeach2[]
199: $h[
200: $.a[1]
201: $.b[2]
202: ]
203: $c[
204: ^h.foreach[key;value]{
205: $.$key[$value]
206: }
207: ]
208: $c.b
1.458 paf 209:
210: @thashforeach[]
211: $h[
212: $.a[1]
213: $.b[2]
214: ]
215: ^h.foreach[key;value]{
216: $key=$value<br>
217: }
1.457 paf 218:
219: @thashdelete[]
220: $h[$.a[1] $.b[2]]
221: was:<br>
222: count=^h._count[] <br>
223: b='$h.b' <br>
224:
225: ^h.delete[b]
226:
227: now:<br>
228: count=^h._count[] <br>
229: b='$h.b'
1.452 paf 230:
231: @sappend[]
232: $test[123]
233: ^test.save[test]
234: ^test.save[append;test]
235:
1.453 paf 236: @tappend[]
237: $test[^table::set{a b
238: a1 b1}]
239: ^test.save[test]
240: $test[^table::set{a b
241: a2 b2}]
242: ^test.save[append;test]
1.452 paf 243:
1.448 paf 244:
245: @tform[]
1.449 paf 246: ^if(def $form:new_file){y}{n}
247: <form method="post" enctype="multipart/form-data">
248: <input type="file" name="new_file" />
1.448 paf 249: <input type=submit>
250: </input>
1.447 paf 251:
252: @formattest[]
253: $size(15.124)
254:
255: ^size.format{%.2f}
1.446 paf 256:
257: @filelist[]
258: $html[^file:list[.;\.html^$]]
259: ^html.menu{
260: $html.name<br>
261: }
262: <hr>
1.431 paf 263:
264: @безнадёжна_попытка_поправить_непоправимое[]
265: $dom_from_disk[^xdoc::load[input.xml]]
266: $dom_created_in_air[^xdoc::create[doc]]
267: ^dom_created_in_air.documentElement.appendChild[^dom_from_disk.documentElement.cloneNode(1)]
268: ^show-xdoc2[$dom_created_in_air]
269:
1.426 parser 270:
1.428 parser 271: @tcache[]
1.496 ! paf 272: ^rem{
1.428 parser 273: #^hashfile:clear[cache]
1.459 paf 274: $code[^hashfile::open[$DB_HOME;cache]]
1.496 ! paf 275: ^code.cache[key](2){
1.430 parser 276: ^math:random(100)
277: # ^code.delete[]
1.428 parser 278: }
1.496 ! paf 279: }
1.428 parser 280:
1.426 parser 281: @thashfileexp[]
1.459 paf 282: $hf[^hashfile::open[$DB_HOME;hashfile]]
1.428 parser 283: $hf.paf[$.value[крут] $.expires(3)]
284: paf=$hf.paf
1.459 paf 285: <hr>
286: ^hf.foreach[key;value]{
287: $key=$value<br>
288: }
1.427 parser 289: <hr>
290: $hash[^hf.hash[]]
291: =$hash.paf=
292: <hr>
1.420 parser 293:
1.423 parser 294: @tcounter[]
1.440 paf 295: ^tcounterone[$DB_HOME]
1.466 paf 296: other root:
297: ^tcounterone[${DB_HOME}2]
298: again, first:
299: ^tcounterone[$DB_HOME]
1.432 paf 300:
301: @tcounterone[DB_HOME]
302: $counter[^hashfile::open[$DB_HOME;counter]]
1.440 paf 303: #^counter.clear[]
1.423 parser 304: ^counter.transaction{
305: # $counter.value(10)
306: $counter.value($counter.value+1)
307: # ^counter.delete[value]
308: $counter.value
309: }
1.424 parser 310: <hr>
1.432 paf 311: ^rem{
1.424 parser 312: $hash[^counter.hash[]]
1.425 parser 313: =$hash.value=
1.424 parser 314: <hr>
1.432 paf 315: }
1.423 parser 316:
317: @tablehash[]
318: $productList[^table::set{id name
319: 1 носки
320: 2 валенки
321: 3 ушанка
322: }]
323:
324: #скажем, у первого дилера
325: $firstPriceList[^table::set{id price
326: 1 0.3
327: 3 1000
328: }]
329:
330: $firstPriceHash[^firstPriceList.hash[id]]
331:
332: ^productList.menu{
333: продукт "$productList.name" | цена у first: $firstPriceHash.[$productList.id].price<br>
334: }
335:
336:
1.420 parser 337: @hashfile[]
338: $hf[^hashfile::assign[hashfile]]
1.423 parser 339: #$hf.paf[крут5]
1.420 parser 340: paf=$hf.paf
1.402 parser 341:
1.417 parser 342: @formclass[]
343: ^$form:CLASS.a=$form:CLASS.a
344:
1.406 parser 345: @domdata[]
1.418 parser 346: ^if(1){
1.422 parser 347: # $a{^hren[]}
1.418 parser 348: }
1.419 parser 349: $a
1.408 parser 350: $xdoc[^xdoc::create[doc]]
351: $doc[$xdoc.documentElement]
1.473 paf 352: $name[^doc.appendChild[^xdoc.createElement[name]]]
1.474 paf 353: $text[^name.appendChild[^xdoc.createTextNode[петросян&coz]]]
1.435 paf 354: ^untaint[as-is]{=$text.nodeValue=}
1.406 parser 355:
356: @domedit[]
357: ^domdata[]
1.404 parser 358: #$paf.nodeName<br>
359: #$doc.documentElement.nodeName<br>
360:
1.406 parser 361: ^show-xnode1[$xdoc.documentElement;0;1]
362: <hr>
363: ^show-xdoc2[$xdoc]
1.411 parser 364: <hr>
1.406 parser 365:
366: @domxslt[]
367: ^domdata[]
1.405 parser 368: ^show-xdoc2[^xdoc.transform[global.xsl;$.param1[123/]]]
1.411 parser 369: <hr>
1.401 parser 370:
371: @lsplit2[]
372: $path[/optics/]
373: $pathTable[^path.lsplit[/]]
374: ^pathTable.menu{
375: ^if(def $pathTable.piece){
376: =$pathTable.piece=
377: }
378: }
379:
1.395 parser 380:
1.397 parser 381: @faceesize[]
382: $k(2)
383: $pict[^image::load[paf.gif]]
384: $small[^image::create($pict.width/$k;$pict.height/$k)]
1.398 parser 385: ^small.copy[$pict](0;0;$pict.width;$pict.height;0;0;$small.width;$small.height;250)
1.397 parser 386: $response:body[^small.gif[]]
387:
1.395 parser 388: @imageresize[]
389: $k(2)
390: $pict[^image::create(400*$k;200*$k)]
391: $pict.line-width(2)
1.444 paf 392: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
393: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-20;$pict.height-20;0+20;360-20;0xff0000)
1.395 parser 394: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
1.444 paf 395: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-20;0x0000ff)
396: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+20;360-20;0xff0000)
397: $response:body[^pict.gif[]]
1.395 parser 398:
1.443 paf 399: #$small[^image::create($pict.width/$k;$pict.height/$k)]
1.396 parser 400: #^small.copy[$pict](0;0;$pict.width;$pict.height;0;0)
1.443 paf 401: #^small.copy[$pict](0;0;$pict.width;$pict.height;0;0;$small.width;$small.height;0)
1.395 parser 402:
1.443 paf 403: #$response:body[^small.gif[]]
1.395 parser 404:
1.388 parser 405:
406: @tintdefault[]
407: #$abc[abc]
408: $abc[33]
409: ^abc.int[z]
410: #^abc.int(123)
1.390 parser 411:
412: @ifassignhash[]
413: $h[^if(1){$.a(1);$.a(2)}]
414: $h.a
1.387 parser 415:
416: @ifpasshash[]
417: $a[$.e[a]]
418: $b[$.e[b]]
1.389 parser 419: ^ifpasshashdest[^if(1){$a;$b}]
1.387 parser 420: #$x[^if(1){$a}{$b}]
421: #^ifpasshashdest[$x]
422:
423: @ifpasshashdest[p]
424: $p.e
425:
426: @movedir[]
427: ^file:move[a;deeper/a]
1.386 parser 428:
429: @replace[]
430: $a[12^;3]
431: ^a.replace[^table::set{from to
432: 2^; !
433: }]
434:
1.385 parser 435:
436: @set[]
437: ^setdata[]
438: ^a.add[$b]
439: add:$a.3<br>
440:
441: ^setdata[]
442: ^a.sub[$b]
443: sub2:$a.2<br>
444: sub1:$a.1<br>
445:
446: ^setdata[]
447: $c[^a.union[$b]]
448: union3:$c.3<br>
449: union2:$c.2<br>
450:
451: ^setdata[]
452: $c[^a.intersection[$b]]
453: intersection3:$c.3<br>
454: intersection2:$c.2<br>
455:
456: ^setdata[]
457: intersects:^if(^a.intersects[$b]){y;n}<br>
458: intersects2:^if(^a.intersects[ ]){y;n}<br>
459:
460:
461: <hr>
462:
463: @setdata[]
464: $a[$.1[a1] $.2[a2]]
465: $b[ $.2[b2] $.3[b3]]
466:
1.383 parser 467:
1.384 parser 468: @hash[]
469: $h[^hash::create[$._default[123]]]
470: $h.paf[not kretin]
471: $h.paf<br>
472: =$h.that=<br>
473:
474: @methresult[]
475: $result[^table::set{1}]
1.377 parser 476:
1.381 parser 477: @terror[]
478: ^error[method z must be called with z]
479:
1.380 parser 480: @syntax1[]
481: #^a[^b]
482:
483: @syntax2[]
1.381 parser 484: #^a[
1.379 parser 485:
1.377 parser 486: @ssave[]
487: $abc[abc]
488: ^abc.save[abc]
1.376 parser 489:
490: @calendar[]
491: 2001;11:<br>
492: $week_days[^date:calendar[rus](2001;11)]
493: <pre>
494: ^week_days.menu{^for[wday](0;7){^if($week_days.$wday){$week_days.$wday; ^; ^;} }<br>}
495: </pre>
1.372 parser 496:
1.375 parser 497: @thash[]
498: $table[^table::set{id name age
499: 1 paf 278
500: 2 пиф 234
501: }]
502: $hash[^table.hash[id;^table::set[nameless]{id
503: name}]]
504: $hash.2.id $hash.2.name $hash.2.age
505:
1.372 parser 506: @tdef[]
507: $s[0]
508: if 0=^if($s){}{n}<br>
509: if def 0=^if(def $s){y}{}<br>
510: <hr>
1.371 parser 511:
512: @ford[]
1.374 parser 513: ^for[i](0;5){$i}{($i)}
1.368 parser 514:
1.370 parser 515: @tif[]
516: ^if[def]{y;n}
517:
1.368 parser 518: @image[]
519: $pict[^image::create(400;200)]
1.379 parser 520: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
521: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-10;$pict.height-10;0+10;360-10;0xff0000)
522: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
523: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-10;0x0000ff)
524: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+10;360-10;0xff0000)
1.368 parser 525: $response:body[^pict.gif[]]
526:
527:
1.366 parser 528:
1.369 parser 529: @mail2[]
1.367 parser 530: ^mail:send[
1.369 parser 531: $.content-type[$.value[text/plain] $.charset[windows-1251]]
532: $.from[Александр Петросян <paf@design.ru>]
1.367 parser 533: $.to[Александр Петросян <paf@design.ru>]
1.369 parser 534: $.subject[проверка]
535: $.body[проверка]
1.367 parser 536: ]
537:
1.366 parser 538: @cookie[]
1.367 parser 539: $env:HTTP_COOKIE<br>
540:
541: #$cookie:переменная[test тест ТЕСТ2]
542: =$cookie:переменная=<br>
543: #$cookie:переменная2[test тест ТЕСТ3]
544: =$cookie:переменная2=<br>
1.412 parser 545: =$cookie:CLASS.переменная2=<br>
1.365 parser 546:
547: @response[]
548: #^if($form:reload){
549: $response:refresh[$.value[0] $.url[./t.html?uri=$env:SERVER_NAME]]
550: #}
1.364 parser 551:
552: @xslt[]
553: ^xdata[]
1.407 parser 554: $transformed[^xdoc.transform[global.xsl;$.param1[123/]]]
555: ^show-xdoc2[$transformed]
1.364 parser 556:
557: @regexp2[]
558: $s[ select]
559: $s[^s.match[^^\s*][]{!}]
560: $s
561:
562: @header[]
563: $response:refresh[
564: $.value[0]
565: $.url[http://design.ru?a=^taint[123]]
566: ]
567:
568: @ttablerem[]
569: $table[^table::load[a.cfg]]
570: ^table.menu{$table.a}
571:
572: @tconnect[]
573: ^connect[mysql://test:test@paf/test?charset=cp1251_koi8&compress=1&timeout=1&named_pipe=1]{
574: $tables[^table::sql{show tables}]
575: #$cols[^tables.columns[]]
576: #$cols.column
577: ^tables.menu{
578: $tables.[Tables_in_test]<br>
579: }
580: }
581:
582: @pcre[]
583: $s[1 2]
584: ^s.match[\s;ig]{!}
585: #^s.match[\d;ig]{!}
586:
587:
588: @regexp[]
589: $s[abcАБВ]
590: ^if(^s.match[б][i]){y}{n}
591:
592: @mail[]
593: #$ORIGINS(1)
594: ^mail:send[
595: $.from[paf@design.ru]
596: $.to[paf@design.ru]
597: $.body[1
598:
599: 2
600:
601:
602: 3]
603: ]
604:
605: @exec[]
1.370 parser 606: $a[^file::exec[fc.exe;;a;b]]
1.364 parser 607: $a.status|$a.stderr<hr>
608:
609: @fori[][i]
610: ^for[i](1;3){... =$i= ...}
611:
1.489 paf 612: @xdata0[]
1.364 parser 613: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
1.468 paf 614: $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251"?>
615: <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->
616: <people>
617: <man id="1" имя="word слово">
618: <name>P«^;AF B</name>
619: </man>
620: <man id="2">
621: <name>ПИФ^taint[&]</name>
622: </man>
623: </people>
624: }]
1.489 paf 625:
626: @xdata[]
627: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
1.490 paf 628: $xdoc[^xdoc::set{^process{<?xml version="1.0" encoding="windows-1251"?>
1.489 paf 629: <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->
630: <people>
631: <man id="1" имя="word слово">
632: <name>P«^;AF B</name>
633: </man>
634: <man id="2">
635: <name>ПИФ^taint[&]</name>
636: </man>
637: </people>
638: }}]
1.364 parser 639:
640: @xml[]
641: ^xdata[]
642:
643: ^show-xdoc2[$xdoc]<hr>
644: #^show-xnode1[$xdoc]<hr>
645: $people[^xdoc.select[*/man]]
646: #^show1[]
647: ^show-xnodes1[$people]<hr>
648: #^people.0.owner.hren[]
649:
1.393 parser 650: ^show-xnode1[^xdoc.selectSingle[*/man[2]/name];0;1]<hr>
1.364 parser 651:
652: by id:
653: ^show-xnode1[^xdoc.getElementById[1];0;1]
654: <hr>
655:
656: @show1[array]
657: ^for[i](0;^array._count[]-1){
658: $x[$array.$i]
659: $x.firstChild.nodeValue:
660: $pattributes[$x.parentNode.attributes]
661: ^if(^pattributes._count[]){
662: $pattributes.id.name=$pattributes.id.nodeValue
663: }
664: <br>
665: }
666:
667: @show-xnodes1[array][i]
668: ^for[i](0;^array._count[]-1){
669: ^show-xnode1[$array.$i;0;1]
670: }
671:
672: @show-xnode1[x;level;single][l]
673: ^if(def $x){
674: ^for[l](0;$level-1){ ^; ^; ^; ^;}
675: ^if($x.nodeType == $xnode:ELEMENT_NODE){
676: <^;$x.nodeName
677: $pairs[$x.attributes]
678: ^if(def $pairs){
679: $names[^pairs._keys[]]
680: ^names.menu{ $names.key="$pairs.[$names.key].nodeValue"}
681: }
682: >^;
683: }{
684: [$x.nodeType]
685: }
686:
687: ^if(def $x.nodeValue){$x.nodeValue}<br>
688: ^show-xnode1[$x.firstChild]($level+1)
689: ^if(!$single){
690: ^show-xnode1[$x.nextSibling]($level)
691: }
692:
693: ^if($x.nodeType == $xnode:ELEMENT_NODE){
694: ^for[l](0;$level-1){ ^; ^; ^; ^;}<^;/$x.nodeName>^;<br>
695: }
696: }
697:
698: @show-xdoc2[xdoc]
1.473 paf 699: ^xdoc.save[out/save.xml;
1.364 parser 700: # $.encoding[windows-1251]
701: $.method[xml]
702: ]
703: $file[^xdoc.file[
704: # $.encoding[windows-1251]
705: $.method[html]
706: ]]
1.473 paf 707: ^file.save[text;out/save_file.html]
1.487 paf 708: #$response:body[^xdoc.file[ $.media-type[text/paf] ]]
709: <pre>^taint[html][^xdoc.string[
710: # $.method[html]
711: # $.version[1.0]
712: # $.encoding[utf-8]
713: # $.omit-xml-declaration[yes]
714: # $.standalone[yes]
715: # $.doctype-public[-//W3C//DTD XHTML]
716: # $.doctype-system[/a/b/c/]
717: # $.indent[no]
718: $.media-type[text/paf]
1.486 paf 719: ]]
1.413 parser 720: </pre>
1.435 paf 721:
E-mail: