Diff for /parser3/src/www/htdocs/Attic/index.html between versions 1.486 and 1.542

version 1.486, 2001/11/21 10:02:13 version 1.542, 2002/01/28 08:20:33
Line 1 Line 1
   @auto[]
   $request:charset[windows-1251]
   $response:charset[windows-1251]
   $response:content-type[$.value[text/html]$.charset[$response:charset]]
   
 @main[]  @main[]
   ^xdocset1[]
   #^regexp3[]
   #^exec2[]
   #^tlock[]
   #^xmloutattrwithoutvalue[]
   #^precisionProblem[]
   #^xpath[]
   #^ttablesetlang[]
   #^mail3[]
   #^ttime[]
   #^tupper[]
   #^treplace[]
   #^xslt2[]
   #^tcache2[]
   #$ORIGINS(1)
   #$t[^table::set{a b} ^table::set{c d}]
 #^ttaintuntaint[]  #^ttaintuntaint[]
 #^tappend2[]  #^tappend2[]
 #^badvsnprintf[]  #^badvsnprintf[]
Line 66 Line 87
 #^exec[]  #^exec[]
 #^fori[]  #^fori[]
 #^tconnect[]  #^tconnect[]
 ^xslt[]  #^xslt[]
 #^xml[]  #^xml[]
 #^header[]  #^header[]
 <hr>  <hr>
 OK  OK
   
   @xdocset1[]
   $d[^xdoc::set{<?xml version="1.0"?><d>=^taint[&]=</d>}]
   ^show_xdoc2[$d]
   
   @regexp3[]
   $s[abcАБВ]
   ^if(^s.match[][i]){y}{n}
   
   
   @exec2[]
   $a[^file::exec[bin/t.cmd]]
   <pre>^taint[$a.text]</pre>|$a.status|$a.stderr<hr>
   
   
   @tlock[]
   ^file:lock[lockfile]{
           code
   }
   
   @xmloutattrwithoutvalue[]
   #$ORIGINS(1)
   $doc[^xdoc::set{<?xml version="1.0"?><doc background="">zz</doc>}]
   $doc[^doc.transform[global.xsl]]
   =^taint[html][^doc.string[$.method[html]]]=
   
   
   
   @precisionProblem[]
   $a[123456789012345678901234567890]
   $b(^a.double[])
   ^b.format{%.20E}
   <hr>
   ^eval(2*2)
   
   @xpath[]
   $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251" ?>
   <document><block><p>привет</p></block></document>
   }]
   #^show_xdoc2[$xdoc]
   $node[^xdoc.selectSingle[/document/block/p]]
   ^if(def $node){
           ^if($node is string){
                   $node
           }{
           ^if($node is hash){
                   ^node._count[]
           }{
                   $node.nodeType
           }
           }
   #$node.firstChild.nodeValue
   }{
           node not found
   }
   
   
   @ttablesetlang[]
   $a-tab-b[a      b
   1       2]
   
   $t[^table::set{$a-tab-b}]
   =$t.a=
   <hr>
   
   $t[^table::set[nameless]{^taint[$a-tab-b]}]
   =$t.0=
   <hr>
   
   $t[^table::set{^untaint{^taint[$a-tab-b]}}]
   =$t.a=
   
   #^t.append{1    2}
   
   @mail3[]
   ^mail:send[
           $.from[Александр Петросян <paf@design.ru>]
           $.to[Александр Петросян <paf@design.ru>]
           $.subject[проверка4]
           $.body[
                   $.text[
                           $.content-type[$.value[text/plain] $.charset[windows-1251]]
                           $.body[проверка]
                   ]
                   $.attachment[
                           $.value[^file::load[text;index.html]]
                           $.file-name[привет всем.html]                   
                   ]
           ]
   ]
   
   
   @ttime[]
   $now[^date::now[]]
   $now.hour:$now.minute
   
   @tupper[]
   $t[abcABCабвАБВ]
   $t<br>
   ^t.upper[]
   
   @treplace[]
   $copy-paste-clean[^table::set{a b
   .       _
   ,       _
   +       _
   &       _
   ?       _
   =       _}]
   
   $cache_key[^taint[в.а,с+я]&был?тут=недавно.cache]
   # почему-то этот replace роняет апач в 500 ошибку :(
   #^cache_key.replace[$copy-paste-clean]
   $test[abc]
   ^test.save[$cache_key]saved<br>
   $cache[^file:list[.;\.cache^$]]
   ^file:delete[$cache_key]deleted($cache.name)<br>
   
   
   
   @xslt2[]
   $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251" ?>
   <document><block><p>привет</p></block></document>
   }]
   ^show_xdoc2[$xdoc]
   ^show_xdoc2[^xdoc.transform[templates/_document.xslt]]
   <hr>
   
   
   @tcache2[]
   ^cache[$DB_HOME/keyключ](2){
           ^math:random(100)
   }
   
 @ttaintuntaint[]  @ttaintuntaint[]
 <!-- некий панковский заголовок с буковкой C в круглых скобках -->^taint[html][  <!-- некий панковский заголовок с буковкой C в круглых скобках -->^taint[html][
   
Line 127  $bred[^int::int[]] Line 281  $bred[^int::int[]]
   
 @xloadwrongtable[]  @xloadwrongtable[]
 $constr[^xdoc::load[wrongtable.xml]]  $constr[^xdoc::load[wrongtable.xml]]
   ^show_xdoc2[$constr]
   
 @xsetwrongtable[]  @xsetwrongtable[]
 $constr[^xdoc::set{<?xml version="1.0" encoding="windows-1251z" ?>  $constr[^xdoc::set{<?xml version="1.0" encoding="windows-1251z" ?>
Line 257  $html[^file:list[.;\.html^$]] Line 412  $html[^file:list[.;\.html^$]]
 $dom_from_disk[^xdoc::load[input.xml]]  $dom_from_disk[^xdoc::load[input.xml]]
 $dom_created_in_air[^xdoc::create[doc]]  $dom_created_in_air[^xdoc::create[doc]]
 ^dom_created_in_air.documentElement.appendChild[^dom_from_disk.documentElement.cloneNode(1)]  ^dom_created_in_air.documentElement.appendChild[^dom_from_disk.documentElement.cloneNode(1)]
 ^show-xdoc2[$dom_created_in_air]  ^show_xdoc2[$dom_created_in_air]
   
   
 @tcache[]  @tcache[]
Line 268  $code[^hashfile::open[$DB_HOME;cache]] Line 423  $code[^hashfile::open[$DB_HOME;cache]]
 #       ^code.delete[]  #       ^code.delete[]
 }  }
   
   
 @thashfileexp[]  @thashfileexp[]
 $hf[^hashfile::open[$DB_HOME;hashfile]]  $hf[^hashfile::open[$DB_HOME;hashfile]]
 $hf.paf[$.value[крут] $.expires(3)]  $hf.paf[$.value[крут] $.expires(3)]
Line 349  $text[^name.appendChild[^xdoc.createText Line 503  $text[^name.appendChild[^xdoc.createText
 #$paf.nodeName<br>  #$paf.nodeName<br>
 #$doc.documentElement.nodeName<br>  #$doc.documentElement.nodeName<br>
   
 ^show-xnode1[$xdoc.documentElement;0;1]  ^show_xnode1[$xdoc.documentElement;0;1]
 <hr>  <hr>
 ^show-xdoc2[$xdoc]  ^show_xdoc2[$xdoc]
 <hr>  <hr>
   
 @domxslt[]  @domxslt[]
 ^domdata[]  ^domdata[]
 ^show-xdoc2[^xdoc.transform[global.xsl;$.param1[123/]]]  ^show_xdoc2[^xdoc.transform[global.xsl;$.param1[123/]]]
 <hr>  <hr>
   
 @lsplit2[]  @lsplit2[]
Line 543  $env:HTTP_COOKIE<br> Line 697  $env:HTTP_COOKIE<br>
 @xslt[]  @xslt[]
 ^xdata[]  ^xdata[]
 $transformed[^xdoc.transform[global.xsl;$.param1[123/]]]  $transformed[^xdoc.transform[global.xsl;$.param1[123/]]]
 ^show-xdoc2[$transformed]  ^show_xdoc2[$transformed]
   
 @regexp2[]  @regexp2[]
 $s[  select]  $s[  select]
Line 600  $a.status|$a.stderr<hr> Line 754  $a.status|$a.stderr<hr>
 @fori[][i]  @fori[][i]
 ^for[i](1;3){... =$i= ...}  ^for[i](1;3){... =$i= ...}
   
 @xdata[]  @xdata0[]
 #$response:content-type[$.value[text/html] $.charset[windows-1251]]  #$response:content-type[$.value[text/html] $.charset[windows-1251]]
 $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251"?>  $xdoc[^xdoc::set{<?xml version="1.0" encoding="windows-1251"?>
 <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->  <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->
Line 614  $xdoc[^xdoc::set{<?xml version="1.0" enc Line 768  $xdoc[^xdoc::set{<?xml version="1.0" enc
 </people>  </people>
 }]  }]
   
   @xdata[]
   #$response:content-type[$.value[text/html] $.charset[windows-1251]]
   $xdoc[^xdoc::set{^process{<?xml version="1.0" encoding="windows-1251"?>
   <!--DOCTYPE people SYSTEM "D:\Y\parser3project\parser3\src\www\htdocs\people.dtd"-->
   <people>
           <man id="1" имя="word слово">
                   <name>P&#171^;AF        B</name>
           </man>
                   <man id="2">
               <name>ПИФ^taint[&]</name>
                   </man>
   </people>
   }}]
   
 @xml[]  @xml[]
 ^xdata[]  ^xdata[]
   
 ^show-xdoc2[$xdoc]<hr>  ^show_xdoc2[$xdoc]<hr>
 #^show-xnode1[$xdoc]<hr>  #^show_xnode1[$xdoc]<hr>
 $people[^xdoc.select[*/man]]  $people[^xdoc.select[*/man]]
 #^show1[]  #^show1[]
 ^show-xnodes1[$people]<hr>  ^show_xnodes1[$people]<hr>
 #^people.0.owner.hren[]  #^people.0.owner.hren[]
   
 ^show-xnode1[^xdoc.selectSingle[*/man[2]/name];0;1]<hr>  ^show_xnode1[^xdoc.selectSingle[*/man[2]/name];0;1]<hr>
   
 by id:  by id:
 ^show-xnode1[^xdoc.getElementById[1];0;1]  ^show_xnode1[^xdoc.getElementById[1];0;1]
 <hr>  <hr>
   
 @show1[array]  @show1[array]
Line 641  by id: Line 809  by id:
         <br>          <br>
 }  }
                   
 @show-xnodes1[array][i]  @show_xnodes1[array][i]
 ^for[i](0;^array._count[]-1){  ^for[i](0;^array._count[]-1){
         ^show-xnode1[$array.$i;0;1]          ^show_xnode1[$array.$i;0;1]
 }  }
   
 @show-xnode1[x;level;single][l]  @show_xnode1[x;level;single][l]
 ^if(def $x){  ^if(def $x){
     ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}      ^for[l](0;$level-1){&nbsp^;&nbsp^;&nbsp^;&nbsp^;}
     ^if($x.nodeType == $xnode:ELEMENT_NODE){      ^if($x.nodeType == $xnode:ELEMENT_NODE){
Line 662  by id: Line 830  by id:
     }      }
           
     ^if(def $x.nodeValue){$x.nodeValue}<br>      ^if(def $x.nodeValue){$x.nodeValue}<br>
     ^show-xnode1[$x.firstChild]($level+1)      ^show_xnode1[$x.firstChild]($level+1)
     ^if(!$single){      ^if(!$single){
             ^show-xnode1[$x.nextSibling]($level)              ^show_xnode1[$x.nextSibling]($level)
     }      }
   
     ^if($x.nodeType == $xnode:ELEMENT_NODE){      ^if($x.nodeType == $xnode:ELEMENT_NODE){
Line 672  by id: Line 840  by id:
     }      }
 }  }
   
 @show-xdoc2[xdoc]  @show_xdoc2[xdoc]
 ^xdoc.save[out/save.xml;  ^xdoc.save[out/save.xml;
 #       $.encoding[windows-1251]  #       $.encoding[utf-8]
         $.method[xml]          $.method[xml]
 ]  ]
 $file[^xdoc.file[  $file[^xdoc.file[
 #       $.encoding[windows-1251]          $.encoding[utf-8]
         $.method[html]          $.method[html]
 ]]  ]]
 ^file.save[text;out/save_file.html]  ^file.save[text;out/save_file.html]
 <pre>^taint[^xdoc.string[  #$response:body[^xdoc.file[     $.media-type[text/paf]  ]]
 #]]  <pre>^taint[html][^xdoc.string[
 #       $.encoding[windows-1251]  
         $.method[html]          $.method[html]
   #       $.encoding[utF-8]
   #       $.omit-xml-declaration[yes]
   #       $.standalone[no]
   #       -$.doctype-public[-//W3C//DTD XHTML]
   #       -$.doctype-system[/a/b/c/]
   #       $.indent[yes]
   #       $.media-type[text/paf]
 ]]  ]]
 </pre>  </pre>
   

Removed from v.1.486  
changed lines
  Added in v.1.542


E-mail: