[Templates-cvs] cvs commit: Template2/docsrc/src/Manual VMethods.tt2

cvs@template-toolkit.org cvs@template-toolkit.org


cvs         06/02/01 07:52:02

  Modified:    docsrc/src/Manual VMethods.tt2
  Log:
  * unshift and push list vmethods accept multiple arguments
  
  Revision  Changes    Path
  1.8       +8 -3      Template2/docsrc/src/Manual/VMethods.tt2
  
  Index: VMethods.tt2
  ===================================================================
  RCS file: /template-toolkit/Template2/docsrc/src/Manual/VMethods.tt2,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- VMethods.tt2	2006/01/30 18:36:09	1.7
  +++ VMethods.tt2	2006/02/01 07:52:01	1.8
  @@ -323,10 +323,15 @@
   
   =item unshift(item), push(item)
   
  -Adds an item to the start/end of a list.
  +The push() method adds an item or items to the end of list.
   
  -    [% mylist.unshift('prev item') %]
  -    [% mylist.push('next item')    %]
  +    [% mylist.push(foo) %]
  +    [% mylist.push(foo, bar) %]
  +    
  +The unshift() method adds an item or items to the start of a list.
  +
  +    [% mylist.unshift(foo) %]
  +    [% mylist.push(foo, bar)    %]
   
   =item shift, pop