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

1.399     parser      1: @main[]
1.446   ! paf         2: ^filelist[]
1.443     paf         3: #^connect[mysql://user:pass@host]{ }
1.431     paf         4: #^безнадёжна_попытка_поправить_непоправимое[]
1.430     parser      5: #^tcache[]
1.428     parser      6: #^thashfileexp[]
1.442     paf         7: #^tcounter[]
1.423     parser      8: #^tablehash[]
1.443     paf         9: #j^hashfile[]
1.417     parser     10: #^formclass[]
1.415     parser     11: #^hren[]
1.446   ! paf        12: #^domedit[]
1.420     parser     13: #^domxslt[]
1.402     parser     14: #^lsplit2[]
1.401     parser     15: #^faceesize[]
1.445     paf        16: #^imageresize[]
1.399     parser     17: #^ifassignhash[]
                     18: #^tintdefault[]
                     19: #$response:status[404]
1.390     parser     20: #^ifpasshash[]
1.387     parser     21: #^movedir[]
                     22: #^replace[]
1.416     parser     23: #^set[]
1.385     parser     24: #^hash[]<hr>
1.384     parser     25: #$t[^methresult[]] ->$t
1.382     parser     26: #^terror[]
1.378     parser     27: #^ssave[]
1.377     parser     28: #^calendar[]
1.376     parser     29: #^thash[]
1.373     parser     30: #^tdef[]
1.375     parser     31: #^ford[]
1.371     parser     32: #^tif[]
1.383     parser     33: #^image[]
1.369     parser     34: #^mail2[]
1.413     parser     35: #^cookie[]
1.365     parser     36: #^response[]
1.364     parser     37: #^regexp2[]
                     38: #^ttablerem[]
                     39: #^pcre[]
                     40: #^regexp[]<hr>
                     41: #^mail[]
                     42: #^exec[]
                     43: #^fori[]
                     44: #^tconnect[]
1.406     parser     45: #^xslt[]
1.395     parser     46: #^xml[]
1.364     parser     47: #^header[]
                     48: OK
1.446   ! paf        49: 
        !            50: @filelist[]
        !            51: $html[^file:list[.;\.html^$]]
        !            52: ^html.menu{
        !            53:        $html.name<br>
        !            54: }
        !            55: <hr>
1.431     paf        56: 
                     57: @безнадёжна_попытка_поправить_непоправимое[]
                     58: $dom_from_disk[^xdoc::load[input.xml]]
                     59: $dom_created_in_air[^xdoc::create[doc]]
                     60: ^dom_created_in_air.documentElement.appendChild[^dom_from_disk.documentElement.cloneNode(1)]
                     61: ^show-xdoc2[$dom_created_in_air]
                     62: 
1.426     parser     63: 
1.428     parser     64: @tcache[]
                     65: #^hashfile:clear[cache]
                     66: $code[^hashfile::open[cache]]
1.430     parser     67: ^code.cache[key](2){
                     68:        ^math:random(100)
                     69: #      ^code.delete[]
1.428     parser     70: }
                     71: 
                     72: 
1.426     parser     73: @thashfileexp[]
                     74: $hf[^hashfile::open[hashfile]]
1.428     parser     75: $hf.paf[$.value[крут] $.expires(3)]
                     76: paf=$hf.paf
1.427     parser     77: <hr>
                     78: $hash[^hf.hash[]]
                     79: =$hash.paf=
                     80: <hr>
1.420     parser     81: 
1.423     parser     82: @tcounter[]
1.440     paf        83: ^tcounterone[$DB_HOME]
                     84: #other root:
                     85: #^tcounterone[${DB_HOME}2]
1.437     paf        86: #again, first:
                     87: #^tcounterone[$DB_HOME]
1.432     paf        88: 
                     89: @tcounterone[DB_HOME]
                     90: $counter[^hashfile::open[$DB_HOME;counter]]
1.440     paf        91: #^counter.clear[]
1.423     parser     92: ^counter.transaction{
                     93: #      $counter.value(10)
                     94:        $counter.value($counter.value+1)
                     95: #      ^counter.delete[value]
                     96:        $counter.value
                     97: }
1.424     parser     98: <hr>
1.432     paf        99: ^rem{
1.424     parser    100: $hash[^counter.hash[]]
1.425     parser    101: =$hash.value=
1.424     parser    102: <hr>
1.432     paf       103: }
1.423     parser    104: 
                    105: @tablehash[]
                    106: $productList[^table::set{id    name
                    107: 1      носки
                    108: 2      валенки
                    109: 3      ушанка
                    110: }]
                    111: 
                    112: #скажем, у первого дилера
                    113: $firstPriceList[^table::set{id price
                    114: 1      0.3
                    115: 3      1000
                    116: }]
                    117: 
                    118: $firstPriceHash[^firstPriceList.hash[id]]
                    119: 
                    120: ^productList.menu{
                    121:     продукт "$productList.name" | цена у first: $firstPriceHash.[$productList.id].price<br>
                    122: }
                    123: 
                    124: 
1.420     parser    125: @hashfile[]
                    126: $hf[^hashfile::assign[hashfile]]
1.423     parser    127: #$hf.paf[крут5]
1.420     parser    128: paf=$hf.paf
1.402     parser    129: 
1.417     parser    130: @formclass[]
                    131: ^$form:CLASS.a=$form:CLASS.a
                    132: 
1.406     parser    133: @domdata[]
1.418     parser    134: ^if(1){
1.422     parser    135: #      $a{^hren[]}
1.418     parser    136: }
1.419     parser    137: $a
1.408     parser    138: $xdoc[^xdoc::create[doc]]
                    139: $doc[$xdoc.documentElement]
1.435     paf       140: $name[^doc.appendChild[^xdoc.createElement{name}]]
                    141: $text[^name.appendChild[^xdoc.createTextNode{петросян&nbsp^;co}]]
                    142: ^untaint[as-is]{=$text.nodeValue=}
1.406     parser    143: 
                    144: @domedit[]
                    145: ^domdata[]
1.404     parser    146: #$paf.nodeName<br>
                    147: #$doc.documentElement.nodeName<br>
                    148: 
1.406     parser    149: ^show-xnode1[$xdoc.documentElement;0;1]
                    150: <hr>
                    151: ^show-xdoc2[$xdoc]
1.411     parser    152: <hr>
1.406     parser    153: 
                    154: @domxslt[]
                    155: ^domdata[]
1.405     parser    156: ^show-xdoc2[^xdoc.transform[global.xsl;$.param1[123/]]]
1.411     parser    157: <hr>
1.401     parser    158: 
                    159: @lsplit2[]
                    160: $path[/optics/]
                    161: $pathTable[^path.lsplit[/]]
                    162: ^pathTable.menu{
                    163:        ^if(def $pathTable.piece){
                    164:                =$pathTable.piece=
                    165:        }
                    166: }
                    167: 
1.395     parser    168: 
1.397     parser    169: @faceesize[]
                    170: $k(2)
                    171: $pict[^image::load[paf.gif]]
                    172: $small[^image::create($pict.width/$k;$pict.height/$k)]
1.398     parser    173: ^small.copy[$pict](0;0;$pict.width;$pict.height;0;0;$small.width;$small.height;250)
1.397     parser    174: $response:body[^small.gif[]]
                    175: 
1.395     parser    176: @imageresize[]
                    177: $k(2)
                    178: $pict[^image::create(400*$k;200*$k)]
                    179: $pict.line-width(2)
1.444     paf       180: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
                    181: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-20;$pict.height-20;0+20;360-20;0xff0000)
1.395     parser    182: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
1.444     paf       183: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-20;0x0000ff)
                    184: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+20;360-20;0xff0000)
                    185: $response:body[^pict.gif[]]
1.395     parser    186: 
1.443     paf       187: #$small[^image::create($pict.width/$k;$pict.height/$k)]
1.396     parser    188: #^small.copy[$pict](0;0;$pict.width;$pict.height;0;0)
1.443     paf       189: #^small.copy[$pict](0;0;$pict.width;$pict.height;0;0;$small.width;$small.height;0)
1.395     parser    190: 
1.443     paf       191: #$response:body[^small.gif[]]
1.395     parser    192: 
1.388     parser    193: 
                    194: @tintdefault[]
                    195: #$abc[abc]
                    196: $abc[33]
                    197: ^abc.int[z]
                    198: #^abc.int(123)
1.390     parser    199: 
                    200: @ifassignhash[]
                    201: $h[^if(1){$.a(1);$.a(2)}]
                    202: $h.a
1.387     parser    203: 
                    204: @ifpasshash[]
                    205: $a[$.e[a]]
                    206: $b[$.e[b]]
1.389     parser    207: ^ifpasshashdest[^if(1){$a;$b}]
1.387     parser    208: #$x[^if(1){$a}{$b}]
                    209: #^ifpasshashdest[$x]
                    210: 
                    211: @ifpasshashdest[p]
                    212: $p.e
                    213: 
                    214: @movedir[]
                    215: ^file:move[a;deeper/a]
1.386     parser    216: 
                    217: @replace[]
                    218: $a[12^;3]
                    219: ^a.replace[^table::set{from    to
                    220: 2^;    !
                    221: }]
                    222: 
1.385     parser    223: 
                    224: @set[]
                    225: ^setdata[]
                    226: ^a.add[$b]
                    227: add:$a.3<br>
                    228: 
                    229: ^setdata[]
                    230: ^a.sub[$b]
                    231: sub2:$a.2<br>
                    232: sub1:$a.1<br>
                    233: 
                    234: ^setdata[]
                    235: $c[^a.union[$b]]
                    236: union3:$c.3<br>
                    237: union2:$c.2<br>
                    238: 
                    239: ^setdata[]
                    240: $c[^a.intersection[$b]]
                    241: intersection3:$c.3<br>
                    242: intersection2:$c.2<br>
                    243: 
                    244: ^setdata[]
                    245: intersects:^if(^a.intersects[$b]){y;n}<br>
                    246: intersects2:^if(^a.intersects[ ]){y;n}<br>
                    247: 
                    248: 
                    249: <hr>
                    250: 
                    251: @setdata[]
                    252: $a[$.1[a1] $.2[a2]]
                    253: $b[        $.2[b2] $.3[b3]]
                    254: 
1.383     parser    255: 
1.384     parser    256: @hash[]
                    257: $h[^hash::create[$._default[123]]]
                    258: $h.paf[not kretin]
                    259: $h.paf<br>
                    260: =$h.that=<br>
                    261: 
                    262: @methresult[]
                    263: $result[^table::set{1}]
1.377     parser    264: 
1.381     parser    265: @terror[]
                    266: ^error[method z must be called with z]
                    267: 
1.380     parser    268: @syntax1[]
                    269: #^a[^b]
                    270: 
                    271: @syntax2[]
1.381     parser    272: #^a[
1.379     parser    273: 
1.377     parser    274: @ssave[]
                    275: $abc[abc]
                    276: ^abc.save[abc]
1.376     parser    277: 
                    278: @calendar[]
                    279: 2001;11:<br>
                    280: $week_days[^date:calendar[rus](2001;11)]
                    281: <pre>
                    282: ^week_days.menu{^for[wday](0;7){^if($week_days.$wday){$week_days.$wday;&nbsp^;&nbsp^;} }<br>}
                    283: </pre>
1.372     parser    284: 
1.375     parser    285: @thash[]
                    286: $table[^table::set{id  name    age
                    287: 1      paf     278
                    288: 2      пиф     234
                    289: }]
                    290: $hash[^table.hash[id;^table::set[nameless]{id
                    291: name}]]
                    292: $hash.2.id $hash.2.name $hash.2.age
                    293: 
1.372     parser    294: @tdef[]
                    295: $s[0]
                    296: if 0=^if($s){}{n}<br>
                    297: if def 0=^if(def $s){y}{}<br>
                    298: <hr>
1.371     parser    299: 
                    300: @ford[]
1.374     parser    301: ^for[i](0;5){$i}{($i)}
1.368     parser    302: 
1.370     parser    303: @tif[]
                    304: ^if[def]{y;n}
                    305: 
1.368     parser    306: @image[]
                    307: $pict[^image::create(400;200)]
1.379     parser    308: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-1;$pict.height-1;0;360;0x000000)
                    309: ^pict.arc($pict.width/2;$pict.height/2;$pict.width-10;$pict.height-10;0+10;360-10;0xff0000)
                    310: #^pict.arc($pict.width/2;$pict.height/2;$pict.width;$pict.height;0;360;0xff0000)
                    311: ^pict.circle($pict.width/2;$pict.height/2;$pict.height/2-10;0x0000ff)
                    312: ^pict.arc($pict.width/2;$pict.height/2;$pict.height-26;$pict.height-26;0+10;360-10;0xff0000)
1.368     parser    313: $response:body[^pict.gif[]]
                    314: 
                    315: 
1.366     parser    316: 
1.369     parser    317: @mail2[]
1.367     parser    318: ^mail:send[
1.369     parser    319:        $.content-type[$.value[text/plain] $.charset[windows-1251]]
                    320:        $.from[Александр Петросян <paf@design.ru>]
1.367     parser    321:        $.to[Александр Петросян <paf@design.ru>]
1.369     parser    322:        $.subject[проверка]
                    323:        $.body[проверка]
1.367     parser    324: ]
                    325: 
1.366     parser    326: @cookie[]
1.367     parser    327: $env:HTTP_COOKIE<br>
                    328: 
                    329: #$cookie:переменная[test тест ТЕСТ2]
                    330: =$cookie:переменная=<br>
                    331: #$cookie:переменная2[test тест ТЕСТ3]
                    332: =$cookie:переменная2=<br>
1.412     parser    333: =$cookie:CLASS.переменная2=<br>
1.365     parser    334: 
                    335: @response[]
                    336: #^if($form:reload){
                    337:        $response:refresh[$.value[0] $.url[./t.html?uri=$env:SERVER_NAME]]
                    338: #}
1.364     parser    339: 
                    340: @xslt[]
                    341: ^xdata[]
1.407     parser    342: $transformed[^xdoc.transform[global.xsl;$.param1[123/]]]
                    343: ^show-xdoc2[$transformed]
1.364     parser    344: 
                    345: @regexp2[]
                    346: $s[  select]
                    347: $s[^s.match[^^\s*][]{!}]
                    348: $s
                    349: 
                    350: @header[]
                    351: $response:refresh[
                    352:        $.value[0]
                    353:        $.url[http://design.ru?a=^taint[123]]
                    354: ]
                    355: 
                    356: @ttablerem[]
                    357: $table[^table::load[a.cfg]]
                    358: ^table.menu{$table.a}
                    359: 
                    360: @tconnect[]
                    361: ^connect[mysql://test:test@paf/test?charset=cp1251_koi8&compress=1&timeout=1&named_pipe=1]{
                    362: $tables[^table::sql{show tables}]
                    363: #$cols[^tables.columns[]]
                    364: #$cols.column
                    365: ^tables.menu{
                    366:        $tables.[Tables_in_test]<br>
                    367: }
                    368: }
                    369: 
                    370: @pcre[]
                    371: $s[1 2]
                    372: ^s.match[\s;ig]{!}
                    373: #^s.match[\d;ig]{!}
                    374: 
                    375: 
                    376: @regexp[]
                    377: $s[abcАБВ]
                    378: ^if(^s.match[б][i]){y}{n}
                    379: 
                    380: @mail[]
                    381: #$ORIGINS(1)
                    382: ^mail:send[
                    383:        $.from[paf@design.ru]
                    384:        $.to[paf@design.ru]
                    385:        $.body[1
                    386:        
                    387:        2
                    388:        
                    389:        
                    390:                3]
                    391: ]
                    392: 
                    393: @exec[]
1.370     parser    394: $a[^file::exec[fc.exe;;a;b]]
1.364     parser    395: $a.status|$a.stderr<hr>
                    396: 
                    397: @fori[][i]
                    398: ^for[i](1;3){... =$i= ...}
                    399: 
                    400: @xdata[]
                    401: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
                    402: $xdoc[^xdoc::load[input.xml]]
                    403: 
                    404: @xml[]
                    405: ^xdata[]
                    406: 
                    407: ^show-xdoc2[$xdoc]<hr>
                    408: #^show-xnode1[$xdoc]<hr>
                    409: $people[^xdoc.select[*/man]]
                    410: #^show1[]
                    411: ^show-xnodes1[$people]<hr>
                    412: #^people.0.owner.hren[]
                    413: 
1.393     parser    414: ^show-xnode1[^xdoc.selectSingle[*/man[2]/name];0;1]<hr>
1.364     parser    415: 
                    416: by id:
                    417: ^show-xnode1[^xdoc.getElementById[1];0;1]
                    418: <hr>
                    419: 
                    420: @show1[array]
                    421: ^for[i](0;^array._count[]-1){
                    422:     $x[$array.$i]
                    423:        $x.firstChild.nodeValue: 
                    424:                $pattributes[$x.parentNode.attributes]
                    425:                ^if(^pattributes._count[]){
                    426:                        $pattributes.id.name=$pattributes.id.nodeValue
                    427:                }
                    428:        <br>
                    429: }
                    430:        
                    431: @show-xnodes1[array][i]
                    432: ^for[i](0;^array._count[]-1){
                    433:        ^show-xnode1[$array.$i;0;1]
                    434: }
                    435: 
                    436: @show-xnode1[x;level;single][l]
                    437: ^if(def $x){
                    438:     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}
                    439:     ^if($x.nodeType == $xnode:ELEMENT_NODE){
                    440:        &lt^;$x.nodeName
                    441:            $pairs[$x.attributes]
                    442:            ^if(def $pairs){
                    443:                $names[^pairs._keys[]]
                    444:                ^names.menu{ $names.key="$pairs.[$names.key].nodeValue"}
                    445:            }
                    446:            &gt^;
                    447:     }{
                    448:        [$x.nodeType]
                    449:     }
                    450:     
                    451:     ^if(def $x.nodeValue){$x.nodeValue}<br>
                    452:     ^show-xnode1[$x.firstChild]($level+1)
                    453:     ^if(!$single){
                    454:            ^show-xnode1[$x.nextSibling]($level)
                    455:     }
                    456: 
                    457:     ^if($x.nodeType == $xnode:ELEMENT_NODE){
                    458:     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}&lt^;/$x.nodeName&gt^;<br>
                    459:     }
                    460: }
                    461: 
                    462: @show-xdoc2[xdoc]
                    463: ^xdoc.save[save.xml;
                    464: #      $.encoding[windows-1251]
                    465:        $.method[xml]
                    466: ]
                    467: $file[^xdoc.file[
                    468: #      $.encoding[windows-1251]
                    469:        $.method[html]
                    470: ]]
                    471: ^file.save[text;save_file.html]
1.435     paf       472: <pre>taint[^xdoc.string[]]
1.364     parser    473: #      $.encoding[windows-1251]
1.413     parser    474: #      $.method[html]
1.364     parser    475: #]]
1.413     parser    476: </pre>
1.435     paf       477: 

E-mail: