Annotation of parser3/www/htdocs/index.html, revision 1.38

1.15      paf         1: #@USE
                      2: #z/t.p
                      3: 
                      4: @autoz[]
                      5: $request:charset[windows-1251]
                      6: $response:charset[windows-1251]
                      7: $response:content-type[$.value[text/html]$.charset[$response:charset]]
                      8: 
1.38    ! paf         9: #@postprocess[body]
        !            10: #<b>$body</b>
        !            11: #$result[123]
1.37      paf        12: 
1.15      paf        13: @main[]
1.38    ! paf        14: $result[hello]
1.36      paf        15: #^invaliddate2[]
                     16: #^process2[]
                     17: #^casehashtext[]
1.35      paf        18: #^subjvaltest[]
                     19: #^tableselect0[]
1.34      paf        20: #^memnotest1[]
1.33      paf        21: #^transparams[]
1.32      paf        22: #^voidparams[]
1.31      paf        23: #^rolls2[]
1.30      paf        24: #^cacheexpireschanging[]
1.29      paf        25: #^cacheexpiresfixed[]
                     26: #^dateoffsets[]
                     27: #^exceptionTypes[]
1.28      paf        28: #^roll2[]
1.27      paf        29: #^rolls[]
1.25      paf        30: #^exceptions1[]
1.22      paf        31: #^locate_by_expr[]
1.18      paf        32: #^method_junction_params{...}
1.17      paf        33: #^verifyCookie[paf]
1.37      paf        34: #^execlangs[]
1.16      paf        35: #$t[^tobjeresult[]]$t.a
                     36: #^xmlprobs[]
1.15      paf        37: #^doubleprobs[]
                     38: #^math:random(-10)
                     39: #^divnamestop[]
                     40: #^arrayclone[]
                     41: #^operator_tricks[]
                     42: #^xoutputrusattr[]
                     43: #^xdocset1[]
                     44: #^regexp3[]
                     45: #^exec2[]
                     46: #^tlock[]
                     47: #^xmloutattrwithoutvalue[]
                     48: #^precisionProblem[]
                     49: #^xpath[]
                     50: #^ttablesetlang[]
                     51: #^mail3[]
                     52: #^ttime[]
                     53: #^tupper[]
                     54: #^treplace[]
                     55: #^xslt2[]
                     56: #^tcache2[]
                     57: #$ORIGINS(1)
                     58: #$t[^table::set{a b} ^table::set{c d}]
                     59: #^ttaintuntaint[]
                     60: #^tappend2[]
                     61: #^badvsnprintf[]
                     62: #^badoracequoting[]
                     63: #^badconstructors[]
                     64: #^xloadwrongtable[]
                     65: #^xsetwrongtable[]
                     66: #^if($form:test){y}{n}
                     67: #^tablecolumnerror[]
                     68: #^roll[]
                     69: #^cookie2[]
                     70: #^tableset[]
                     71: #^math:PI.format{%.30f}
                     72: #^xchildren[]
                     73: #^thashforeach3[]
                     74: #^thashforeach2[]
                     75: #^thashforeach[]
                     76: #^thashdelete[]
                     77: #^connect[mysql://user:pass@cd.rinet.ru/db]{^void:sql{z} }
                     78: #^tappend[]
                     79: #^sappend[]
                     80: #^eval(10\3)<br>
                     81: #^tform[]
                     82: #^formattest[]
                     83: #^filelist[]
                     84: #^connect[mysql://user:pass@host]{ }
                     85: #^безнадёжна_попытка_поправить_непоправимое[]
                     86: #^tcache[]
                     87: #^thashfileexp[]
                     88: #^tcounter[]
                     89: #^tablehash[]
                     90: #j^hashfile[]
                     91: #^formclass[]
                     92: #^hren[]
                     93: #^domedit[]
                     94: #^domxslt[]
                     95: #^lsplit2[]
                     96: #^faceesize[]
                     97: #^imageresize[]
                     98: #^ifassignhash[]
                     99: #^tintdefault[]
                    100: #$response:status[404]
                    101: #^ifpasshash[]
                    102: #^movedir[]
                    103: #^replace[]
                    104: #^set[]
                    105: #^hash[]<hr>
                    106: #$t[^methresult[]] ->$t
                    107: #^terror[]
                    108: #^ssave[]
                    109: #^calendar[]
                    110: #^thash[]
                    111: #^tdef[]
                    112: #^ford[]
                    113: #^tif[]
                    114: #^image[]
                    115: #^mail2[]
                    116: #^cookie[]
                    117: #^response[]
                    118: #^regexp2[]
                    119: #^ttablerem[]
                    120: #^pcre[]
                    121: #^regexp[]<hr>
                    122: #^mail[]
                    123: #^exec[]
                    124: #^fori[]
                    125: #^tconnect[]
                    126: #^xslt[]
                    127: #^xml[]
                    128: #^header[]
                    129: <hr>
                    130: OK
1.34      paf       131: 
1.36      paf       132: @invaliddate2[]
                    133: $d[^date::create(1018946575/60/60)] ^d.sql-string[]
                    134: 
                    135: @process2[]
                    136: ^^process{
                    137:        ^process{
                    138:                ^$a[^^if(0){^$.k[y]}{^$.k[^^hren[]n]}] ^$a.k
                    139:        }
                    140: }
                    141: 
1.35      paf       142: @casehashtext[]
                    143: $tt[1]
                    144: $tmp[
                    145:         ^switch[$tt]{
                    146:                 ^case[1]{
                    147:                         $.aaa[123]
                    148:                 }
                    149:                 ^case[DEFAULT]{
                    150:                         $.bbb[456]
                    151:                 }
                    152:         }
1.36      paf       153:         shit!
1.35      paf       154: ]
1.36      paf       155: #$tmp
1.35      paf       156: $tmp.aaa
                    157: 
                    158: @subjvaltest[]
                    159: $a12[val]
                    160: $b[12]
                    161: $a$b
                    162: 
1.34      paf       163: @tableselect0[]
                    164: $person[^table::create{name    height
                    165: paf    1.77
                    166: шохин  2.07
                    167: moko   1.77
                    168: }]
                    169: $nottoohigh[^person.select($person.height<2)]
                    170: ^nottoohigh.menu{$nottoohigh.name<br>}
1.32      paf       171: 
                    172: @transparams[]
                    173: $idoc[^xdoc::create{<?xml version="1.0" ?><doc/>}]
                    174: $odoc[^idoc.transform[global.xsl;
                    175:        $.param1['1']
                    176:        $.param2['2']
                    177: ]]
                    178: <pre>^taint[^odoc.string[$.method[html]]]
                    179: 
                    180: @memnotest1[]
                    181: ^for[i](0;4000){
                    182: 
                    183:  $xxxx[$i]
                    184:  $xxxx
                    185: 
                    186: }
                    187: 
                    188: @memnotest1notes[]
                    189: одна итерация цикла:
                    190: [Mon Apr  8 20:12:02 2002] execution-------------------------|
1.35      paf       191: '469641+=28 wcodeframe -> 0 !optimize[3]''469669+=49 string от {} -> 0 optimize[3]'
1.32      paf       192: [Mon Apr  8 20:12:02 2002] 12:STRING__WRITE
                    193: [Mon Apr  8 20:12:02 2002]  "|| "
                    194: [Mon Apr  8 20:12:02 2002] 12:WITH_ROOT
                    195: [Mon Apr  8 20:12:02 2002] 13:VALUE
                    196: [Mon Apr  8 20:12:02 2002]  "xxxx" string
1.35      paf       197: [Mon Apr  8 20:12:02 2002] 14:CREATE_EWPOOL'469377+=24 wcodeframe -> 0 !optimize[1]''469401+=49 string -> 41 !optimize[7]'
1.32      paf       198: [Mon Apr  8 20:12:02 2002] 16:WITH_READ
                    199: [Mon Apr  8 20:12:02 2002] 17:VALUE
                    200: [Mon Apr  8 20:12:02 2002]  "i" string
                    201: [Mon Apr  8 20:12:02 2002] 18:GET_ELEMENT
1.35      paf       202: [Mon Apr  8 20:12:02 2002] 17:WRITE_VALUE'469452+=40 MAX_NUMBER -> !~2 actual digits''469492+=49 -> 41 !'
                    203: [Mon Apr  8 20:12:02 2002] 16:REDUCE_EWPOOL'469541+=24 VString -> 0 optimize[5]'
1.32      paf       204: [Mon Apr  8 20:12:02 2002] 15:CONSTRUCT_VALUE
                    205: [Mon Apr  8 20:12:02 2002] 12:STRING__WRITE
                    206: [Mon Apr  8 20:12:02 2002]  "| "
                    207: [Mon Apr  8 20:12:02 2002] 12:WITH_READ
                    208: [Mon Apr  8 20:12:02 2002] 13:VALUE
                    209: [Mon Apr  8 20:12:02 2002]  "xxxx" string
                    210: [Mon Apr  8 20:12:02 2002] 14:GET_ELEMENT
                    211: [Mon Apr  8 20:12:02 2002] 13:WRITE_VALUE'469573+=41 string expand nothing for now'
                    212: [Mon Apr  8 20:12:02 2002] 12:STRING__WRITE
1.35      paf       213: [Mon Apr  8 20:12:02 2002]  "||"'469617+=24 VString -> 0 !optimize[6]'
1.32      paf       214: [Mon Apr  8 20:12:02 2002] <-ja returned
                    215: [Mon Apr  8 20:12:02 2002] ja->
                    216: 
                    217: 201/328=0.612804878049 %%optimized
                    218: 
                    219: 1.
                    220: CREATE_*POOL
                    221:     сделать
                    222: *POOL_POOLED+CODE
                    223:     где
                    224:         wwrapper
                    225:         и(возможно) wcodeframe
                    226:         +string
                    227:         стековая переменная
                    228: 
                    229: 2.
                    230: избавиться от обёртки при возврате результата process [см. тело _for]
                    231: 
                    232: 3.
                    233: сделать callback для process, чтобы вынести invariants из _for & co.
                    234: 
                    235: 4.
                    236:  @todo склеить get_element и write_value (при вставлении? write_value)
                    237: 
                    238: 5.
                    239: reduce_*pool -> вариант получить именно string, без VString обёртки [часто
                    240: обёртка сразу выбрасывается = не нужна]
                    241: 
                    242: 6.
                    243: process вариант получить именно string, без VString обёртки [часто обёртка
                    244: сразу выбрасывается = не нужна]
                    245: 
                    246: 7.
                    247: string head, убить 8 байт неправильной link
1.31      paf       248: 
                    249: @voidparams[]
                    250: ^voidparamsm[$form:field]
                    251: 
                    252: @voidparamsm[p]
                    253: ^p.int(123)
1.29      paf       254: 
1.30      paf       255: @rolls2[]
                    256: $now[^date::now[]]
                    257: $d[^date::create($now.year;$now.month)] ^d.sql-string[]<br>
                    258: ^for[i](1;12){
                    259:        ^d.roll[month](-1) ^d.sql-string[]<br>
                    260: }
                    261: 
1.29      paf       262: @cacheexpireschanging[]
                    263: ^cache[$DB_HOME/keyключ][^date::now(+1)]{ ^rem{1 day}
                    264:     ^cache[^date::now(+4/24/60/60)]
                    265: #    ^cache(2)
1.30      paf       266: #    ^cache(0)
1.29      paf       267:        ^math:random(100)
                    268: }
                    269: 
                    270: 
                    271: 
                    272: @cacheexpiresfixed[]
                    273: ^cache[$DB_HOME/keyключ][^date::now(+2/24/60/60)]{
                    274:        ^math:random(100)
                    275: }
                    276: 
                    277: @dateoffsets[]
                    278: $d[^date::create(^date::now[]+1/24/60)]
                    279: #$d[^date::now(+1/24/60)]
                    280: ^d.sql-string[]
                    281: #$d
1.26      paf       282: 
1.28      paf       283: @exceptionTypes[]
                    284: #    parser.compile       ^test[}                компиляция (непарная скобка, ...)
                    285: #    parser.runtime       ^if(0).                параметры (больше/меньше, чем нужно, не тех типов, ...)
                    286: #    number.zerodivision  ^eval(1/0) ^eval(1%0)
                    287: #    number.format        ^eval(abc*5)
                    288: #    file.missing         ^file:delete[delme]                       not found
                    289: #    file.access          ^table::load[.]                       no rights
                    290: #    image.format         ^image::measure[index.html]                        not gif/jpg
                    291: #    sql.connect          ^connect[mysql://baduser:pass@host/db]{}                       not found/timeout
                    292: #    sql.execute          ^connect[mysql://okuser:pass@host/db]{^void:sql{select bad}}                       syntax error
                    293: #    xml                  ^xdoc::create{<forgot?>}                       any error in xml/xslt libs
                    294: #    smtp.connect                                not found/timeout
                    295: #    smtp.execute                                communication error
                    296: 
1.26      paf       297: @roll2[]
                    298: $d[^date::create(2002;4;2;2;2;3)] ^d.sql-string[]<br>
1.27      paf       299: ^d.roll[day](+365*3+1) ^d.sql-string[]<br>
1.26      paf       300: 
1.25      paf       301: 
                    302: @rolls[]
                    303: $d[^date::create(2002;4;4)]
                    304: ^d.sql-string[]<br>
                    305: ^for[i](1;7){
                    306: ^d.roll[day](-1)
                    307: ^d.sql-string[]<br>
                    308: }
                    309: <hr>
                    310: $d[^date::create(2002;3;28)]
                    311: ^d.sql-string[]<br>
                    312: ^for[i](1;7){
                    313: ^d.roll[day](+1)
                    314: ^d.sql-string[]<br>
                    315: }
                    316: <hr>
                    317: $d[^date::create(2002;12;3)]
                    318: ^d.sql-string[]<br>
                    319: ^for[i](1;14){
                    320: ^d.roll[day](-1)
                    321: ^d.sql-string[]<br>
                    322: }
                    323: <hr>
                    324: $d[^date::create(2002;10;19)]
                    325: ^d.sql-string[]<br>
                    326: ^for[i](1;14){
                    327: ^d.roll[day](+1)
                    328: ^d.sql-string[]<br>
                    329: }
                    330: 
                    331: 
                    332: 
                    333: 
                    334: 
1.22      paf       335: 
                    336: @exceptions1[]
                    337: ^try{
                    338:        aaa
1.24      paf       339:        ^throw[custom1;paf;is stupid]
1.22      paf       340: }{
1.24      paf       341:        ^if($exception.type eq custom1){
1.28      paf       342: #              $exception.handled(1)
                    343:        ^throw[$exception]
1.24      paf       344:                type=$exception.type<br>
                    345:            source=$exception.source<br>
                    346:            file=$exception.file<br>
                    347:            lineno=$exception.lineno<br>
                    348:        comment=$exception.comment<br>
                    349:        }
1.22      paf       350: }
1.21      paf       351: 
                    352: @locate_by_expr[]
                    353: $t[^table::create{a    b
                    354: 1      nok
                    355: 2      ok
                    356: 3      nok
                    357: }]
                    358: ^if(^t.locate($t.a==2)){$t.b}{n}
1.17      paf       359: 
                    360: @method_junction_params[param]
                    361: ^if($param is junction){junction}{ne junction}
                    362: 
                    363: @verifyCookie[value] 
                    364: ^if($cookie:dummyvote eq $value){ 
                    365:        $result(1) 
                    366: }{ 
                    367:        $cookie:dummyvote[$value] 
                    368:        $result(0) 
                    369: }
1.16      paf       370: 
                    371: @execlangs[]
1.20      paf       372: $f[^file::exec[test.pl]]
1.36      paf       373: err:$f.stderr<br>
1.16      paf       374: ^process{$f.text}
                    375: #$c[^t.columns[]]
                    376: #^c.menu{
                    377: #* $c.column<br>
                    378: #}
1.36      paf       379: c:$t.c<br>
1.16      paf       380: 
                    381: @tobjeresult[]
                    382: ^table::create{a
                    383: 12}
1.15      paf       384: 
                    385: @xmlprobs[]
                    386: $xmlDataType[^xdoc::load[program.xml]]
                    387: #<pre>^taint[^xmlDataType.string[]]
                    388: $xmlDataTypes[^xmlDataType.select[programs/program[@id=4]/data]]
                    389: #=^xmlDataTypes._count[]=
                    390: =^xmlDataTypes.0.getAttribute[type-id]=
                    391: 
                    392: @doubleprobs[]
                    393: $1(^math:radians(180))
                    394: $2($math:PI)
                    395: ^if(^1.format[%.10f]==^2.format[%.10f]){y;n}
                    396: ^if($1==$2){y;n}
                    397: ^if(^math:radians(180)==$math:PI){y;n}
                    398: 
                    399: 
                    400: @divnamestop[]
                    401: $a(10)
                    402: ^eval($a\3)
                    403: 
                    404: @arrayclone[]
                    405: $t[^table::create{a    b
                    406: 1      11
                    407: 2      22
                    408: }]
                    409: $c[^table::create[$t]]
                    410: ^c.append{2    33}
                    411: ^t.count[]
                    412: ^c.count[]
                    413: 
                    414: @operator_tricks[]
                    415: ^if(1){$a[^t[]]}
                    416: $a!
                    417: $a($b)
                    418: ^if(1){y}{n}
                    419: $MAIN:a(^t[] eq OK)
                    420: #$MAIN:a(1)
                    421: ^if($a){y}{n}
                    422: #^if(1){y}{n}
                    423: $form:if
                    424: $a[$.n[1]]
                    425: $a.if
                    426: 
                    427: @xoutputrusattr[]
                    428: $d[^xdoc::set{<?xml version="1.0" encoding="windows-1251"?><d attr="привет"/>}]
                    429: ^show_xdoc2[$d]
                    430: 
                    431: @xdocset1[]
                    432: $d[^xdoc::set{<?xml version="1.0"?><d>=^taint[&]=</d>}]
                    433: ^show_xdoc2[$d]
                    434: 
                    435: @regexp3[]
                    436: $s[abcАБВ]
                    437: ^if(^s.match[][i]){y}{n}
                    438: 
                    439: 
                    440: @exec2[]
                    441: $a[^file::exec[bin/t.cmd]]
                    442: <pre>^taint[$a.text]</pre>|$a.status|$a.stderr<hr>
                    443: 
                    444: 
                    445: @tlock[]
                    446: ^file:lock[lockfile]{
                    447:        code
                    448: }
                    449: 
                    450: @xmloutattrwithoutvalue[]
                    451: #$ORIGINS(1)
                    452: $doc[^xdoc::set{<?xml version="1.0"?><doc background="">zz</doc>}]
                    453: $doc[^doc.transform[global.xsl]]
                    454: =^taint[html][^doc.string[$.method[html]]]=
                    455: 
                    456: 
                    457: 
                    458: @precisionProblem[]
                    459: $a[123456789012345678901234567890]
                    460: $b(^a.double[])
                    461: ^b.format{%.20E}
                    462: <hr>
                    463: ^eval(2*2)
                    464: 
                    465: @xpath[]
                    466: $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251" ?>
                    467: <document><block><p>привет</p></block></document>
                    468: }]
                    469: #^show_xdoc2[$xdoc]
                    470: $node[^xdoc.selectSingle[/document/block/p]]
                    471: ^if(def $node){
                    472:        ^if($node is string){
                    473:                $node
                    474:        }{
                    475:        ^if($node is hash){
                    476:                ^node._count[]
                    477:        }{
                    478:                $node.nodeType
                    479:        }
                    480:        }
                    481: #$node.firstChild.nodeValue
                    482: }{
                    483:        node not found
                    484: }
                    485: 
                    486: 
                    487: @ttablesetlang[]
                    488: $a-tab-b[a     b
                    489: 1      2]
                    490: 
                    491: $t[^table::set{$a-tab-b}]
                    492: =$t.a=
                    493: <hr>
                    494: 
                    495: $t[^table::set[nameless]{^taint[$a-tab-b]}]
                    496: =$t.0=
                    497: <hr>
                    498: 
                    499: $t[^table::set{^untaint{^taint[$a-tab-b]}}]
                    500: =$t.a=
                    501: 
                    502: #^t.append{1   2}
                    503: 
                    504: @mail3[]
                    505: ^mail:send[
                    506:        $.from[Александр Петросян <paf@design.ru>]
                    507:        $.to[Александр Петросян <paf@design.ru>]
                    508:        $.subject[проверка4]
                    509:        $.body[
                    510:                $.text[
                    511:                        $.content-type[$.value[text/plain] $.charset[windows-1251]]
                    512:                        $.body[проверка]
                    513:                ]
                    514:                $.attachment[
                    515:                        $.value[^file::load[text;index.html]]
                    516:                        $.file-name[привет всем.html]                   
                    517:                ]
                    518:        ]
                    519: ]
                    520: 
                    521: 
                    522: @ttime[]
                    523: $now[^date::now[]]
                    524: $now.hour:$now.minute
                    525: 
                    526: @tupper[]
                    527: $t[abcABCабвАБВ]
                    528: $t<br>
                    529: ^t.upper[]
                    530: 
                    531: @treplace[]
                    532: $copy-paste-clean[^table::set{a b
                    533: .      _
                    534: ,      _
                    535: +      _
                    536: &      _
                    537: ?      _
                    538: =      _}]
                    539: 
                    540: $cache_key[^taint[в.а,с+я]&был?тут=недавно.cache]
                    541: # почему-то этот replace роняет апач в 500 ошибку :(
                    542: #^cache_key.replace[$copy-paste-clean]
                    543: $test[abc]
                    544: ^test.save[$cache_key]saved<br>
                    545: $cache[^file:list[.;\.cache^$]]
                    546: ^file:delete[$cache_key]deleted($cache.name)<br>
                    547: 
                    548: 
                    549: 
                    550: @xslt2[]
                    551: $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251" ?>
                    552: <document><block><p>привет</p></block></document>
                    553: }]
                    554: ^show_xdoc2[$xdoc]
                    555: ^show_xdoc2[^xdoc.transform[templates/_document.xslt]]
                    556: <hr>
                    557: 
                    558: 
                    559: @tcache2[]
                    560: ^cache[$DB_HOME/keyключ](2){
                    561:        ^math:random(100)
                    562: }
                    563: 
                    564: @ttaintuntaint[]
                    565: <!-- некий панковский заголовок с буковкой C в круглых скобках -->^taint[html][
                    566: 
                    567: ]zz
                    568: <hr>
                    569: ^untaint[html]{1^taint[  ]2  3}
                    570: 
                    571: 
                    572: @tappend2[]
                    573: $t[^table::set{a       b}]^t.append{1  2}$t.a
                    574: 
                    575: @badvsnprintf[]
                    576: ^connect[zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz]{
                    577: }
                    578: 
                    579: 
                    580: @badoracequoting[]
                    581: $SQL.connect-string[oracle://webspb:webpwd@mts?NLS_LANG=RUSSIAN_AMERICA.CL8MSWIN1251&NLS_DATE_FORMAT=YYYY-MM-DD HH24:MI:SS]
                    582: ^connect[$SQL.connect-string]{
                    583: ^void:sql{delete from paf}
                    584: ^void:sql{insert into paf values (1, '$form:text')}
                    585: $paf[^table::sql{select * from paf}]
                    586: ^paf.menu{
                    587:        $paf.id: ^untaint{$paf.block}<hr>
                    588: 
                    589: }
                    590: <hr>
                    591: 
                    592: 
                    593: ^rem{
                    594: $news[^table::sql{select description from news}[$.limit(3)]]
                    595: ^news.menu{
                    596:        ^untaint{$news.description}<hr>
                    597: 
                    598: }
                    599: <hr>
                    600: }
                    601: 
                    602: $tables[^table::sql{select table_name from user_tables}]
                    603: ^tables.menu{
                    604: $tables.table_name<br>
                    605: }
                    606: 
                    607: }
                    608: <hr>
                    609: $env:PATH
                    610: 
                    611: @badconstructors[]
                    612: $bred[^string::length[]]
                    613: $bred[^response::clear[]]
                    614: $bred[^int::int[]]
                    615: 
                    616: 
                    617: @xloadwrongtable[]
                    618: $constr[^xdoc::load[wrongtable.xml]]
                    619: ^show_xdoc2[$constr]
                    620: 
                    621: @xsetwrongtable[]
                    622: $constr[^xdoc::set{<?xml version="1.0" encoding="windows-1251z" ?>
                    623: <block-list>^untaint[as-is]{$constructor}</block-list>}]
                    624: 
                    625: 
                    626: @tablecolumnerror[]
                    627: $t[^table::set{a}]
                    628: $t.$a
                    629: 
                    630: @roll[]
                    631: #$date[^date::set(1970;1;2)]
                    632: #^date.roll[month](-1)
                    633: $date[^date::set(2038;1;1)]
                    634: ^date.roll[month](+1)
                    635: $date.year  $date.month  $date.day
                    636: 
                    637: @cookie2[]
                    638: #=$cookie:clientType[$.value[test]]=<br>
                    639: =$cookie:clientType=<br>
                    640: 
                    641: 
                    642: @tableset[]
                    643: $a[^table::set{a
                    644: 1
                    645: 2}]
                    646: ^eval(100\$a)
                    647: 
                    648: 
                    649: 
                    650: @zzz[]
                    651: 
                    652: 
                    653: $constructor[
                    654: <block1 name="main_srvr" type="0" label="Основное тело" />
                    655: <block2 name="main_srvr2" type="0" label="Основное тело" />
                    656: ]
                    657: 
                    658: $constr[^xdoc::set{<?xml version="1.0" encoding="windows-1251" ?>
                    659: <block-list>^untaint[as-is]{$constructor}</block-list>}]
                    660: 
                    661: $children[$constr.documentElement.childNodes]
                    662: ^if($children){
                    663: ^for[i](1;^children._count[]){
                    664:        $node[$children.$i]
                    665:        $node.nodeName<br>
                    666: }
                    667: }
                    668:    
                    669: 
                    670: @thashforeach3[]
                    671: $h[
                    672:        $.a[1] 
                    673:        $.b[2]
                    674: ]
                    675: $c[^table::set{a
                    676: ^h.foreach[key;value]{$value
                    677: }}]
                    678: $c.a
                    679: 
                    680: @thashforeach2[]
                    681: $h[
                    682:        $.a[1] 
                    683:        $.b[2]
                    684: ]
                    685: $c[
                    686: ^h.foreach[key;value]{
                    687:        $.$key[$value]
                    688: }
                    689: ]
                    690: $c.b
                    691: 
                    692: @thashforeach[]
                    693: $h[
                    694:        $.a[1] 
                    695:        $.b[2]
                    696: ]
                    697: ^h.foreach[key;value]{
                    698:        $key=$value<br>
                    699: }
                    700: 
                    701: @thashdelete[]
                    702: $h[$.a[1] $.b[2]]
                    703: was:<br>
                    704: count=^h._count[] <br>
                    705: b='$h.b' <br>
                    706: 
                    707: ^h.delete[b] 
                    708: 
                    709: now:<br>
                    710: count=^h._count[] <br>
                    711: b='$h.b' 
                    712: 
                    713: @sappend[]
                    714: $test[123]
                    715: ^test.save[test]
                    716: ^test.save[append;test]
                    717: 
                    718: @tappend[]
                    719: $test[^table::set{a    b
                    720: a1     b1}]
                    721: ^test.save[test]
                    722: $test[^table::set{a    b
                    723: a2     b2}]
                    724: ^test.save[append;test]
                    725: 
                    726: 
                    727: @tform[]
                    728: ^if(def $form:new_file){y}{n}
                    729: <form method="post" enctype="multipart/form-data">
                    730: <input type="file" name="new_file" />
                    731: <input type=submit>
                    732: </input>
                    733: 
                    734: @formattest[]
                    735: $size(15.124)
                    736: 
                    737: ^size.format{%.2f}
                    738: 
                    739: @filelist[]
                    740: $html[^file:list[.;\.html^$]]
                    741: ^html.menu{
                    742:        $html.name<br>
                    743: }
                    744: <hr>
                    745: 
                    746: @безнадёжна_попытка_поправить_непоправимое[]
                    747: $dom_from_disk[^xdoc::load[input.xml]]
                    748: $dom_created_in_air[^xdoc::create[doc]]
                    749: ^dom_created_in_air.documentElement.appendChild[^dom_from_disk.documentElement.cloneNode(1)]
                    750: ^show_xdoc2[$dom_created_in_air]
                    751: 
                    752: 
                    753: @tcache[]
                    754: #^hashfile:clear[cache]
                    755: $code[^hashfile::open[$DB_HOME;cache]]
                    756: ^code.cache[key](2){
                    757:        ^math:random(100)
                    758: #      ^code.delete[]
                    759: }
                    760: 
                    761: @thashfileexp[]
                    762: $hf[^hashfile::open[$DB_HOME;hashfile]]
                    763: $hf.paf[$.value[крут] $.expires(3)]
                    764: paf=$hf.paf
                    765: <hr>
                    766: ^hf.foreach[key;value]{
                    767:        $key=$value<br>
                    768: }
                    769: <hr>
                    770: $hash[^hf.hash[]]
                    771: =$hash.paf=
                    772: <hr>
                    773: 
                    774: @tcounter[]
                    775: ^tcounterone[$DB_HOME]
                    776: other root:
                    777: ^tcounterone[${DB_HOME}2]
                    778: again, first:
                    779: ^tcounterone[$DB_HOME]
                    780: 
                    781: @tcounterone[DB_HOME]
                    782: $counter[^hashfile::open[$DB_HOME;counter]]
                    783: #^counter.clear[]
                    784: ^counter.transaction{
                    785: #      $counter.value(10)
                    786:        $counter.value($counter.value+1)
                    787: #      ^counter.delete[value]
                    788:        $counter.value
                    789: }
                    790: <hr>
                    791: ^rem{
                    792: $hash[^counter.hash[]]
                    793: =$hash.value=
                    794: <hr>
                    795: }
                    796: 
                    797: @tablehash[]
                    798: $productList[^table::set{id    name
                    799: 1      носки
                    800: 2      валенки
                    801: 3      ушанка
                    802: }]
                    803: 
                    804: #скажем, у первого дилера
                    805: $firstPriceList[^table::set{id price
                    806: 1      0.3
                    807: 3      1000
                    808: }]
                    809: 
                    810: $firstPriceHash[^firstPriceList.hash[id]]
                    811: 
                    812: ^productList.menu{
                    813:     продукт "$productList.name" | цена у first: $firstPriceHash.[$productList.id].price<br>
                    814: }
                    815: 
                    816: 
                    817: @hashfile[]
                    818: $hf[^hashfile::assign[hashfile]]
                    819: #$hf.paf[крут5]
                    820: paf=$hf.paf
                    821: 
                    822: @formclass[]
                    823: ^$form:CLASS.a=$form:CLASS.a
                    824: 
                    825: @domdata[]
                    826: ^if(1){
                    827: #      $a{^hren[]}
                    828: }
                    829: $a
                    830: $xdoc[^xdoc::create[doc]]
                    831: $doc[$xdoc.documentElement]
                    832: $name[^doc.appendChild[^xdoc.createElement[name]]]
                    833: $text[^name.appendChild[^xdoc.createTextNode[петросян&coz]]]
                    834: ^untaint[as-is]{=$text.nodeValue=}
                    835: 
                    836: @domedit[]
                    837: ^domdata[]
                    838: #$paf.nodeName<br>
                    839: #$doc.documentElement.nodeName<br>
                    840: 
                    841: ^show_xnode1[$xdoc.documentElement;0;1]
                    842: <hr>
                    843: ^show_xdoc2[$xdoc]
                    844: <hr>
                    845: 
                    846: @domxslt[]
                    847: ^domdata[]
                    848: ^show_xdoc2[^xdoc.transform[global.xsl;$.param1[123/]]]
                    849: <hr>
                    850: 
                    851: @lsplit2[]
                    852: $path[/optics/]
                    853: $pathTable[^path.lsplit[/]]
                    854: ^pathTable.menu{
                    855:        ^if(def $pathTable.piece){
                    856:                =$pathTable.piece=
                    857:        }
                    858: }
                    859: 
                    860: 
                    861: @faceesize[]
                    862: $k(2)
                    863: $pict[^image::load[paf.gif]]
                    864: $small[^image::create($pict.width/$k;$pict.height/$k)]
                    865: ^small.copy[$pict](0;0;$pict.width;$pict.height;0;0;$small.width;$small.height;250)
                    866: $response:body[^small.gif[]]
                    867: 
                    868: @imageresize[]
                    869: $k(2)
                    870: $pict[^image::create(400*$k;200*$k)]
                    871: $pict.line-width(2)
                    872: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
                    873: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-20;$pict.height-20;0+20;360-20;0xff0000)
                    874: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
                    875: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-20;0x0000ff)
                    876: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+20;360-20;0xff0000)
                    877: $response:body[^pict.gif[]]
                    878: 
                    879: #$small[^image::create($pict.width/$k;$pict.height/$k)]
                    880: #^small.copy[$pict](0;0;$pict.width;$pict.height;0;0)
                    881: #^small.copy[$pict](0;0;$pict.width;$pict.height;0;0;$small.width;$small.height;0)
                    882: 
                    883: #$response:body[^small.gif[]]
                    884: 
                    885: 
                    886: @tintdefault[]
                    887: #$abc[abc]
                    888: $abc[33]
                    889: ^abc.int[z]
                    890: #^abc.int(123)
                    891: 
                    892: @ifassignhash[]
                    893: $h[^if(1){$.a(1);$.a(2)}]
                    894: $h.a
                    895: 
                    896: @ifpasshash[]
                    897: $a[$.e[a]]
                    898: $b[$.e[b]]
                    899: ^ifpasshashdest[^if(1){$a;$b}]
                    900: #$x[^if(1){$a}{$b}]
                    901: #^ifpasshashdest[$x]
                    902: 
                    903: @ifpasshashdest[p]
                    904: $p.e
                    905: 
                    906: @movedir[]
                    907: ^file:move[a;deeper/a]
                    908: 
                    909: @replace[]
                    910: $a[12^;3]
                    911: ^a.replace[^table::set{from    to
                    912: 2^;    !
                    913: }]
                    914: 
                    915: 
                    916: @set[]
                    917: ^setdata[]
                    918: ^a.add[$b]
                    919: add:$a.3<br>
                    920: 
                    921: ^setdata[]
                    922: ^a.sub[$b]
                    923: sub2:$a.2<br>
                    924: sub1:$a.1<br>
                    925: 
                    926: ^setdata[]
                    927: $c[^a.union[$b]]
                    928: union3:$c.3<br>
                    929: union2:$c.2<br>
                    930: 
                    931: ^setdata[]
                    932: $c[^a.intersection[$b]]
                    933: intersection3:$c.3<br>
                    934: intersection2:$c.2<br>
                    935: 
                    936: ^setdata[]
                    937: intersects:^if(^a.intersects[$b]){y;n}<br>
                    938: intersects2:^if(^a.intersects[ ]){y;n}<br>
                    939: 
                    940: 
                    941: <hr>
                    942: 
                    943: @setdata[]
                    944: $a[$.1[a1] $.2[a2]]
                    945: $b[        $.2[b2] $.3[b3]]
                    946: 
                    947: 
                    948: @hash[]
                    949: $h[^hash::create[$._default[123]]]
                    950: $h.paf[not kretin]
                    951: $h.paf<br>
                    952: =$h.that=<br>
                    953: 
                    954: @methresult[]
                    955: $result[^table::set{1}]
                    956: 
                    957: @terror[]
                    958: ^error[method z must be called with z]
                    959: 
                    960: @syntax1[]
                    961: #^a[^b]
                    962: 
                    963: @syntax2[]
                    964: #^a[
                    965: 
                    966: @ssave[]
                    967: $abc[abc]
                    968: ^abc.save[abc]
                    969: 
                    970: @calendar[]
                    971: 2001;11:<br>
                    972: $week_days[^date:calendar[rus](2001;11)]
                    973: <pre>
                    974: ^week_days.menu{^for[wday](0;7){^if($week_days.$wday){$week_days.$wday;&nbsp^;&nbsp^;} }<br>}
                    975: </pre>
                    976: 
                    977: @thash[]
                    978: $table[^table::set{id  name    age
                    979: 1      paf     278
                    980: 2      пиф     234
                    981: }]
                    982: $hash[^table.hash[id;^table::set[nameless]{id
                    983: name}]]
                    984: $hash.2.id $hash.2.name $hash.2.age
                    985: 
                    986: @tdef[]
                    987: $s[0]
                    988: if 0=^if($s){}{n}<br>
                    989: if def 0=^if(def $s){y}{}<br>
                    990: <hr>
                    991: 
                    992: @ford[]
                    993: ^for[i](0;5){$i}{($i)}
                    994: 
                    995: @tif[]
                    996: ^if[def]{y;n}
                    997: 
                    998: @image[]
                    999: $pict[^image::create(400;200)]
                   1000: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
                   1001: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-10;$pict.height-10;0+10;360-10;0xff0000)
                   1002: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
                   1003: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-10;0x0000ff)
                   1004: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+10;360-10;0xff0000)
                   1005: $response:body[^pict.gif[]]
                   1006: 
                   1007: 
                   1008: 
                   1009: @mail2[]
                   1010: ^mail:send[
                   1011:        $.content-type[$.value[text/plain] $.charset[windows-1251]]
                   1012:        $.from[Александр Петросян <paf@design.ru>]
                   1013:        $.to[Александр Петросян <paf@design.ru>]
                   1014:        $.subject[проверка]
                   1015:        $.body[проверка]
                   1016: ]
                   1017: 
                   1018: @cookie[]
                   1019: $env:HTTP_COOKIE<br>
                   1020: 
                   1021: #$cookie:переменная[test тест ТЕСТ2]
                   1022: =$cookie:переменная=<br>
                   1023: #$cookie:переменная2[test тест ТЕСТ3]
                   1024: =$cookie:переменная2=<br>
                   1025: =$cookie:CLASS.переменная2=<br>
                   1026: 
                   1027: @response[]
                   1028: #^if($form:reload){
                   1029:        $response:refresh[$.value[0] $.url[./t.html?uri=$env:SERVER_NAME]]
                   1030: #}
                   1031: 
                   1032: @xslt[]
                   1033: ^xdata[]
                   1034: $transformed[^xdoc.transform[global.xsl;$.param1[123/]]]
                   1035: ^show_xdoc2[$transformed]
                   1036: 
                   1037: @regexp2[]
                   1038: $s[  select]
                   1039: $s[^s.match[^^\s*][]{!}]
                   1040: $s
                   1041: 
                   1042: @header[]
                   1043: $response:refresh[
                   1044:        $.value[0]
                   1045:        $.url[http://design.ru?a=^taint[123]]
                   1046: ]
                   1047: 
                   1048: @ttablerem[]
                   1049: $table[^table::load[a.cfg]]
                   1050: ^table.menu{$table.a}
                   1051: 
                   1052: @tconnect[]
                   1053: ^connect[mysql://test:test@paf/test?charset=cp1251_koi8&compress=1&timeout=1&named_pipe=1]{
                   1054: $tables[^table::sql{show tables}]
                   1055: #$cols[^tables.columns[]]
                   1056: #$cols.column
                   1057: ^tables.menu{
                   1058:        $tables.[Tables_in_test]<br>
                   1059: }
                   1060: }
                   1061: 
                   1062: @pcre[]
                   1063: $s[1 2]
                   1064: ^s.match[\s;ig]{!}
                   1065: #^s.match[\d;ig]{!}
                   1066: 
                   1067: 
                   1068: @regexp[]
                   1069: $s[abcАБВ]
                   1070: ^if(^s.match[б][i]){y}{n}
                   1071: 
                   1072: @mail[]
                   1073: #$ORIGINS(1)
                   1074: ^mail:send[
                   1075:        $.from[paf@design.ru]
                   1076:        $.to[paf@design.ru]
                   1077:        $.body[1
                   1078:        
                   1079:        2
                   1080:        
                   1081:        
                   1082:                3]
                   1083: ]
                   1084: 
                   1085: @exec[]
                   1086: $a[^file::exec[fc.exe;;a;b]]
                   1087: $a.status|$a.stderr<hr>
                   1088: 
                   1089: @fori[][i]
                   1090: ^for[i](1;3){... =$i= ...}
                   1091: 
                   1092: @xdata0[]
                   1093: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
                   1094: $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251"?>
                   1095: <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->
                   1096: <people>
                   1097:        <man id="1" имя="word слово">
                   1098:                <name>P&#171^;AF        B</name>
                   1099:        </man>
                   1100:                <man id="2">
                   1101:                        <name>ПИФ^taint[&]</name>
                   1102:                </man>
                   1103: </people>
                   1104: }]
                   1105: 
                   1106: @xdata[]
                   1107: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
                   1108: $xdoc[^xdoc::set{^process{<?xml version="1.0" encoding="windows-1251"?>
                   1109: <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->
                   1110: <people>
                   1111:        <man id="1" имя="word слово">
                   1112:                <name>P&#171^;AF        B</name>
                   1113:        </man>
                   1114:                <man id="2">
                   1115:             <name>ПИФ^taint[&]</name>
                   1116:                </man>
                   1117: </people>
                   1118: }}]
                   1119: 
                   1120: @xml[]
                   1121: ^xdata[]
                   1122: 
                   1123: ^show_xdoc2[$xdoc]<hr>
                   1124: #^show_xnode1[$xdoc]<hr>
                   1125: $people[^xdoc.select[*/man]]
                   1126: #^show1[]
                   1127: ^show_xnodes1[$people]<hr>
                   1128: #^people.0.owner.hren[]
                   1129: 
                   1130: ^show_xnode1[^xdoc.selectSingle[*/man[2]/name];0;1]<hr>
                   1131: 
                   1132: by id:
                   1133: ^show_xnode1[^xdoc.getElementById[1];0;1]
                   1134: <hr>
                   1135: 
                   1136: @show1[array]
                   1137: ^for[i](0;^array._count[]-1){
                   1138:     $x[$array.$i]
                   1139:        $x.firstChild.nodeValue: 
                   1140:                $pattributes[$x.parentNode.attributes]
                   1141:                ^if(^pattributes._count[]){
                   1142:                        $pattributes.id.name=$pattributes.id.nodeValue
                   1143:                }
                   1144:        <br>
                   1145: }
                   1146:        
                   1147: @show_xnodes1[array][i]
                   1148: ^for[i](0;^array._count[]-1){
                   1149:        ^show_xnode1[$array.$i;0;1]
                   1150: }
                   1151: 
                   1152: @show_xnode1[x;level;single][l]
                   1153: ^if(def $x){
                   1154:     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}
                   1155:     ^if($x.nodeType == $xnode:ELEMENT_NODE){
                   1156:        &lt^;$x.nodeName
                   1157:            $pairs[$x.attributes]
                   1158:            ^if(def $pairs){
                   1159:                $names[^pairs._keys[]]
                   1160:                ^names.menu{ $names.key="$pairs.[$names.key].nodeValue"}
                   1161:            }
                   1162:            &gt^;
                   1163:     }{
                   1164:        [$x.nodeType]
                   1165:     }
                   1166:     
                   1167:     ^if(def $x.nodeValue){$x.nodeValue}<br>
                   1168:     ^show_xnode1[$x.firstChild]($level+1)
                   1169:     ^if(!$single){
                   1170:            ^show_xnode1[$x.nextSibling]($level)
                   1171:     }
                   1172: 
                   1173:     ^if($x.nodeType == $xnode:ELEMENT_NODE){
                   1174:     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}&lt^;/$x.nodeName&gt^;<br>
                   1175:     }
                   1176: }
                   1177: 
                   1178: @show_xdoc2[xdoc]
                   1179: ^xdoc.save[out/save.xml;
                   1180: #      $.encoding[utf-8]
                   1181:        $.method[xml]
                   1182: ]
                   1183: $file[^xdoc.file[
                   1184:        $.encoding[utf-8]
                   1185:        $.method[html]
                   1186: ]]
                   1187: ^file.save[text;out/save_file.html]
                   1188: #$response:body[^xdoc.file[    $.media-type[text/paf]  ]]
                   1189: <pre>^taint[html][^xdoc.string[
                   1190:        $.method[html]
                   1191: #      $.encoding[utF-8]
                   1192: #      $.omit-xml-declaration[yes]
                   1193: #      $.standalone[no]
                   1194: #      -$.doctype-public[-//W3C//DTD XHTML]
                   1195: #      -$.doctype-system[/a/b/c/]
                   1196: #      $.indent[yes]
                   1197: #      $.media-type[text/paf]
                   1198: ]]
                   1199: </pre>

E-mail: