home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 November / Chip_2003-11_cd1.bin / software / dave / dqsd.exe / searches / lipsum.xml < prev    next >
Text File  |  2002-11-19  |  3KB  |  79 lines

  1. <search function="lipsum">
  2.   <name>Lorem Ipsum Generator</name>
  3.   <category>Reference</category>
  4.   <contributor>Glenn Carr</contributor>
  5.   <link>http://www.lipsum.com/</link>
  6.   <email>glenn at glenncarr dot com</email>
  7.   <description>
  8.   Generate Loren Ipsum text
  9.     <div class="helpboxDescLabels">Parameters:</div>
  10.     <table class="helpboxDescTable">
  11.       <tr><td>[count]</td><td> - </td><td>Number of paragraphs or lists to generate - default is 1.</td></tr>
  12.     </table>
  13.     <div class="helpboxDescLabels">Switches:</div>
  14.     <table class="helpboxDescTable">
  15.       <tr><td>/paragraphs</td><td> - </td><td>[default] Generate paragraphs</td></tr>
  16.       <tr><td>/lists</td><td> - </td><td>Generate list groups</td></tr>
  17.       <tr><td>/random</td><td> - </td><td>Don't start with the standard "Lorem ipsum dolor sit amet..."</td></tr>
  18.     </table>
  19.     <div class="helpboxDescLabels">Examples:</div>
  20.     <table class="helpboxDescTable">
  21.       <tr><td>lipsum /lists</td></tr>
  22.       <tr><td>lipsum 10 /ran</td></tr>
  23.       <tr><td>lipsum 3 /lists</td></tr>
  24.     </table>
  25.   </description>
  26.   <form name="lipsumf"
  27.         method="post"
  28.         action="http://www.lipsum.com/cgi-bin/lipsum.pl">
  29.     <input type="hidden" name="amount" value="1" />
  30.     <input type="hidden" name="start" value="yes" />
  31.     <input type="hidden" name="what" value="paras" />
  32.     <COMMENT>
  33.       The input element above, "what" was a set of radio buttons with the following options...
  34.       "paras", "words", "bytes", "lists"
  35.     </COMMENT>
  36.   </form>
  37.   <script><![CDATA[
  38.     function lipsum(q)
  39.     {
  40.       var defaultItemCount = "1";
  41.       
  42.       if ( q == "" )
  43.         q = defaultItemCount;
  44.     
  45.       if( nullArgs("lipsum", q) )
  46.         return;
  47.         
  48.       document.lipsumf.what.value = "paras";
  49.       document.lipsumf.start.value = "yes";
  50.  
  51.       var args = parseArgs(q, "paragraphs, lists, random");
  52.       for (var iSwitch = 0; iSwitch < args.switches.length; iSwitch++)
  53.       {
  54.         switch( args.switches[iSwitch].name )
  55.         {
  56.           case "lists":
  57.             document.lipsumf.what.value = "lists";
  58.             break;
  59.           case "random":
  60.             document.lipsumf.start.value = "";
  61.             break;
  62.         }
  63.       }
  64.  
  65.       document.lipsumf.amount.value = args.q.length > 0 ? args.q : defaultItemCount;
  66.  
  67.       submitForm(lipsumf);
  68.     }
  69.   ]]></script>
  70.   <copyright>
  71.     The following applies if this file is included and distributed with Dave's Quick Search Deskbar:
  72.     Copyright (c) 2002 David Bau; Distributed under the terms of the GNU Public License, Version 2 (http://www.gnu.org/copyleft/gpl.txt)
  73.   </copyright>
  74.   <created_by>
  75.     This search file was initially created on 11/19/02 at 16:22:08
  76.     by Dave's Quick Search Deskbar Search Wizard version 1.0.0 ,
  77.     Copyright (c) 2002 Glenn Carr; Distributed under the terms of the GNU General Public License, Version 2
  78.   </created_by>
  79. </search>