Home | Products | Consulting | Forums | Support | Order | 1-800-752-0455
  Main
Index
Search
Posts
Who's
Online
Log
In

Home: Discontinued Products: Article Manager 1:
User search with dropdowns

 

 


snichols
User

Mar 26, 2007, 12:22 PM

Post #1 of 7 (1462 views)
Shortcut
User search with dropdowns Can't Post

Hi, it is about a year since I did any work on the AM side of one of sites, so I'm rusty and I'm stumped!

I want to include a search box within an index template - see http://www.cib.uk.com/artman/publish/cat_index_33.shtml

I then want the results to appear on the same template, just listing those that meet the search requirements basically and not the whole category set.

The search parameters I have coded obviously need tweaking, but how can I get this to work? At the moment it pulls up the standard search results template.

Do I have to edit this to make it look like the index template I want to use? Or do I use an SSI?

Just want to say how great AM is working for me - www.cib.uk.com has bene running now for 2.5 years with barely a glitch, complete with latest headlines, RSS etc.

Steve


Donna
Staff / Moderator


Mar 26, 2007, 2:55 PM

Post #2 of 7 (1460 views)
Shortcut
Re: [snichols] User search with dropdowns [In reply to] Can't Post

Hi Steve!

You can specify an alternate template by adding this to your search form (somewhere within the <form> </form> tags):

<input type="hidden" name="template" value="search/your_template_here.html">

Then, make a copy of the search results template and modify it to look however you'd like.

Give that a try and let me know how it works for you. :)

Donna


Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.


snichols
User

Mar 27, 2007, 12:06 AM

Post #3 of 7 (1452 views)
Shortcut
Re: [Donna] User search with dropdowns [In reply to] Can't Post

Hmm! Now I get the error "Sorry, the template you've requested is not a registered template."

How do register them?



Steve


Donna
Staff / Moderator


Mar 27, 2007, 8:56 AM

Post #4 of 7 (1445 views)
Shortcut
Re: [snichols] User search with dropdowns [In reply to] Can't Post

That actually just means that the template doesn't exist. :) Make sure that you've created a template and put it into the directory you're referring to, and it'll show up just fine.

Donna


Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.


snichols
User

Mar 27, 2007, 12:12 PM

Post #5 of 7 (1438 views)
Shortcut
Re: [Donna] User search with dropdowns [In reply to] Can't Post

Wa-hey! What an idiot. Well, I'm getting there - it now works-ish.

See http://www.cib.uk.com/artman/publish/cat_index_33.shtml

I have put four articles in as a test. The search box uses the code:

<td class="bg_search_box">

<form action="http://www.cib.uk.com/cgi-bin/artman/exec/search.cgi?&cat=33" method="post">
<input type="text" name="keyword" size=40>
<input type="submit" value="Go" name="submit2">
<br>
<div align=center><span class="advancedsearch_link"></span></div>
</form>

But when you search it looks at every article on the site, not just those in Cat 33. Now, OK, I'm being stupid again, but what have I done wrong?

Steve


ross
Staff / Moderator


Mar 27, 2007, 4:45 PM

Post #6 of 7 (1432 views)
Shortcut
Re: [snichols] User search with dropdowns [In reply to] Can't Post

Hi Steve

There is just one more adjustment I think you'll need to make. The part where you are telling it look in category 33 actually needs to be a form element instead of a variable in the action attribute. Does that make sense? Try this code instead:


Code
<form action=" "http://www.cib.uk.com/cgi-bin/artman/exec/search.cgi" method="post">  
<input type="hidden" name=cat value="33"
<input type="text" name="keyword" size=40>
<input type="submit" value="Go" name="submit2">
<br>
<div align=center><span class="advancedsearch_link"></span></div>
</form>


That should get you going. Of course, let me know how you make out Smile.
-----------------------------------------------------------
Cheers,
Ross Fairbairn - Product Specialist
support@interactivetools.com


Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.




snichols
User

Mar 27, 2007, 10:58 PM

Post #7 of 7 (1428 views)
Shortcut
Re: [ross] User search with dropdowns [In reply to] Can't Post

Ah! got it. It should be:

<form action="http://www.cib.uk.com/cgi-bin/artman/exec/search.cgi?" method="post">
<input type="hidden" name="cat" value="33">
<input type="text" name="keyword" size=40>
<input type="submit" value="Go" name="submit2">
<br>
<div align=center><span class="advancedsearch_link"></span></div>
</form>

Note the quotes around "cat" and the closed greater than.

Cheers, Steve


(This post was edited by snichols on Mar 27, 2007, 11:08 PM)

 
 
 


Search for (options)
Products
CMS Builder
Article Manager
Realty Manager
Listings Manager
Order Now
Services
Priority Consulting
Support
Online Documentation
Support Forums
Support Homepage
Company Info
12 reasons to choose us!
Meet the team
Monthly newsletter
Contact Us
Toll Free: 1-800-752-0455
Phone: (604) 689-3347
Sales | Support
Conditions of Use | Privacy Policy | Copyright © interactivetools.com 2008
#201 - 2730 Commercial Drive, Vancouver BC Canada V5N 5P4