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

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

E-mail: