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

1.312     parser      1: @main[]
1.352     parser      2: #^ttablerem[]
1.349     parser      3: #^pcre[]
1.340     parser      4: #^regexp[]<hr>
1.339     parser      5: #^mail[]
1.334     parser      6: #^exec[]
1.333     parser      7: #^fori[]
1.351     parser      8: #^tconnect[]
1.352     parser      9: ^xslt[]
1.351     parser     10: OK
                     11: 
                     12: @ttablerem[]
                     13: $table[^table::load[a.cfg]]
                     14: ^table.menu{$table.a}
                     15: 
                     16: @tconnect[]
1.353   ! parser     17: ^connect[mysql://test:test@paf/test?charset=cp1251_koi8&compress=1&timeout=1&named_pipe=1]{
1.350     parser     18: $tables[^table::sql{show tables}]
                     19: #$cols[^tables.columns[]]
                     20: #$cols.column
                     21: ^tables.menu{
                     22:        $tables.[Tables_in_test]<br>
                     23: }
                     24: }
1.348     parser     25: 
                     26: @pcre[]
                     27: $s[1 2]
                     28: ^s.match[\s;ig]{!}
                     29: #^s.match[\d;ig]{!}
                     30: 
1.339     parser     31: 
                     32: @regexp[]
                     33: $s[abcÀÁÂ]
                     34: ^if(^s.match[á][i]){y}{n}
1.338     parser     35: 
                     36: @mail[]
                     37: #$ORIGINS(1)
                     38: ^mail:send[
                     39:        $.from[paf@design.ru]
                     40:        $.to[paf@design.ru]
                     41:        $.body[1
                     42:        
                     43:        2
                     44:        
                     45:        
                     46:                3]
                     47: ]
1.332     parser     48: 
1.334     parser     49: @exec[]
                     50: $a[^file::exec[fc.exe;a;b]]
                     51: $a.status|$a.stderr<hr>
                     52: 
1.332     parser     53: @fori[][i]
                     54: ^for[i](1;3){... =$i= ...}
1.307     parser     55: 
1.312     parser     56: @xslt[]
1.351     parser     57: #$response:content-type[$.value[text/html] $.charset[windows-1251]]
1.347     parser     58: $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251"?>
1.345     parser     59: #<!DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd">
1.312     parser     60: 
                     61: <people>
1.353   ! parser     62:        <man id="1" èìÿ="word ñëîâî">
1.344     parser     63:                <name>P&#171^;AFB</name>
1.312     parser     64:        </man>
                     65:        <man id="2">
                     66:                <name>ÏÈÔ</name>
                     67:        </man>
                     68: </people>
                     69: }]
                     70: 
1.331     parser     71: ^show-xdoc2[$xdoc]<hr>
                     72: #^show-xnode1[$xdoc]<hr>
                     73: $people[^xdoc.select[*/man]]
1.319     parser     74: #^show1[]
1.331     parser     75: ^show-xnodes1[$people]<hr>
1.316     parser     76: #^people.0.owner.hren[]
1.312     parser     77: 
1.331     parser     78: ^show-xnode1[^xdoc.select-single[*/man[2]/name];0;1]<hr>
1.318     parser     79: 
1.334     parser     80: by id:
1.335     parser     81: ^show-xnode1[^xdoc.getElementById[1];0;1]
1.334     parser     82: <hr>
                     83: 
                     84: @show1[array]
                     85: ^for[i](0;^array._count[]-1){
                     86:     $x[$array.$i]
1.333     parser     87:        $x.firstChild.nodeValue: 
                     88:                $pattributes[$x.parentNode.attributes]
1.314     parser     89:                ^if(^pattributes._count[]){
1.333     parser     90:                        $pattributes.id.name=$pattributes.id.nodeValue
1.314     parser     91:                }
                     92:        <br>
1.312     parser     93: }
1.318     parser     94:        
1.331     parser     95: @show-xnodes1[array][i]
1.315     parser     96: ^for[i](0;^array._count[]-1){
1.331     parser     97:        ^show-xnode1[$array.$i;0;1]
1.314     parser     98: }
                     99: 
1.333     parser    100: @show-xnode1[x;level;single][l]
                    101: ^if(def $x){
1.318     parser    102:     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}
1.333     parser    103:     ^if($x.nodeType == $xnode:ELEMENT_NODE){
                    104:        &lt^;$x.nodeName
                    105:            $pairs[$x.attributes]
1.318     parser    106:            ^if(def $pairs){
                    107:                $names[^pairs._keys[]]
1.333     parser    108:                ^names.menu{$names.key=$pairs.[$names.key].nodeValue }
1.318     parser    109:            }
                    110:            &gt^;
                    111:     }{
1.333     parser    112:        [$x.nodeType]
1.318     parser    113:     }
                    114:     
1.333     parser    115:     ^if(def $x.nodeValue){$x.nodeValue}<br>
                    116:     ^show-xnode1[$x.firstChild]($level+1)
1.318     parser    117:     ^if(!$single){
1.333     parser    118:            ^show-xnode1[$x.nextSibling]($level)
1.318     parser    119:     }
                    120: 
1.333     parser    121:     ^if($x.nodeType == $xnode:ELEMENT_NODE){
                    122:     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}&lt^;/$x.nodeName&gt^;<br>
1.318     parser    123:     }
1.315     parser    124: }
1.320     parser    125: 
1.331     parser    126: @show-xdoc2[xdoc]
                    127: ^xdoc.save[save.xml;
1.347     parser    128: #      $.encoding[windows-1251]
1.321     parser    129:        $.method[xml]
                    130: ]
1.331     parser    131: $file[^xdoc.file[
1.347     parser    132: #      $.encoding[windows-1251]
1.321     parser    133:        $.method[html]
                    134: ]]
1.322     parser    135: ^file.save[text;save_file.html]
1.340     parser    136: ^taint[^xdoc.string[]]
1.347     parser    137: #      $.encoding[windows-1251]
1.328     parser    138: #      $.method[xml]
1.342     parser    139: #]]

E-mail: