Thanks, Glenn, it works! I've attached it in case anyone else is
interested.

Sarah


-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Glenn Carr
Sent: Monday, September 30, 2002 1:31 AM
To: [EMAIL PROTECTED]
Subject: RE: [DQSD-Devel] Help with PHP Builder search


Sarah [sorry I called you Paul],

One thing I noticed is that you need to use args.q instead of q.  The
value of args.q is the value of the search string with the switches
removed. Change the script to set document.phpbf.words.value to args.q
and it should work.

You could also consolidate the switch a bit...

case "mail":
default:
  document.phpbf.config.value = "mail";
  break;

Later,
Glenn

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]On Behalf Of Mr. 
> Sanders
> Sent: Sunday, September 29, 2002 10:04 PM
> To: [EMAIL PROTECTED]
> Subject: RE: [DQSD-Devel] Help with PHP Builder search
>
>
> Thanks, Glenn, I fixed that, and now the switches work. But if I do a 
> search with no switch, I get not results at all, and if I do use a 
> switch, the switch is included in the search. So, if I search 'phpb 
> array /mail', the search results returned are for 'array and mail'. 
> Any ideas?
>
> TIA
>
> Sarah
>
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]] On Behalf Of Glenn 
> Carr
> Sent: Sunday, September 29, 2002 10:00 PM
> To: [EMAIL PROTECTED]
> Subject: RE: [DQSD-Devel] Help with PHP Builder search
>
>
> Paul,
>
> The call to parseArgs has "manual, lists" as the switches it expects. 
> Change this to "manual, mail" and it should work for you.
>
> Glenn
>
> BTW, there's a newer version of the wizard (0.9.1) that has a few 
> improvements
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]]On Behalf Of Mr. 
> > Sanders
> > Sent: Sunday, September 29, 2002 6:24 PM
> > To: [EMAIL PROTECTED]
> > Subject: [DQSD-Devel] Help with PHP Builder search
> >
> >
> > I've been trying to make a search for PHPBuilder.com, using the 
> > search
>
> > wizard (which is great, btw). I ran the wizard, then edited the xml 
> > file. I even checked out other searches as examples of how the 
> > search should look, but apparently I am doing something wrong, 
> > because the switches don't seem to work. If I run a search for 'phpb

> > array /mail',
>
> > instead of searching the mail lists, it searches for 'array and 
> > mail';
>
> > and no matter what, it always searches the manual. Can someone 
> > please take a look at my attached xml file and let me know where I 
> > am going wrong? Thanks!
> >
> > Sarah
> >
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf 
> _______________________________________________
> DQSD-Devel mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/dqsd-devel
>
>
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf 
> _______________________________________________
> DQSD-Devel mailing list
> [EMAIL PROTECTED] 
> https://lists.sourceforge.net/lists/listinfo/dqsd-devel



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf _______________________________________________
DQSD-Devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dqsd-devel
<search function="phpb">
  <name>PHPBulider</name>
  <email>[EMAIL PROTECTED]</email>
  <description>
		PHPBuilder.com search.<br/>
		<div class="helpboxDescLabels">Switches:</div>
		<table class="helpboxDescTable">
			<tr><td>/mail</td><td> - </td><td>Search all mail lists.</td></tr>
			<tr><td>/manual</td><td> - </td><td>Search manual.</td></tr>
		</table>
		<div class="helpboxDescLabels">Examples:</div>
		<table class="helpboxDescTable">
			<tr><td>phpb mail</td></tr>
			<tr><td>phpb array /manual</td></tr>
		</table>
  </description>
  <category>Computers</category>
  <contributor>Sarah Sweeney</contributor>
  <link>http://www.phpbuilder.com/</link>
	
  <form name="phpbf" method="post" action="http://www.phpbuilder.com/search/";>
    <input type="hidden" name="sort" value="Score" />
    <input type="hidden" name="method" value="and" />
    <input type="hidden" name="config" />
    <input type="hidden" name="restrict" value="" />
    <input type="hidden" name="exclude" value="" />
    <input type="hidden" name="words" />
  </form>

  <script><![CDATA[
    function phpb(q)
    {
      var args = parseArgs(q, "manual, mail");
      
      if( nullArgs("phpb", q) )
        return;
		  else if ( args.switches.length == 1 )
      { switch( args.switches[0].name )
        { case "manual":
            document.phpbf.config.value = "manual";
			      break;
          case "mail":
          default:
            document.phpbf.config.value = "mail";
			      break;
        }
      }

      document.phpbf.words.value = args.q;

      submitForm(phpbf);
    }
  ]]></script>
  <copyright>
    The following applies if this file is included and distributed with Dave's Quick Search Deskbar:
    Copyright (c) 2002 David Bau; Distributed under the terms of the GNU Public License, Version 2 (http://www.gnu.org/copyleft/gpl.txt)
  </copyright>
  <created_by>
    This search file was initially created on 09/11/02 at 14:55:37
    by Dave's Quick Search Deskbar Search Wizard version 0.7 (beta),
    Copyright (c) 2002 Glenn Carr; Distributed under the terms of the GNU General Public License, Version 2
  </created_by>
</search>

Reply via email to