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