Annotation of parser3/src/www/htdocs/index.html, revision 1.501

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

E-mail: