 |

gfweb
User
Feb 15, 2003, 1:09 PM
Post #1 of 5
(1985 views)
Shortcut
|
|
custom search query templates
|
Can't Post
|
|
Hi There, I am trying to figure out how to supply a custom search_query.html page for each individual client that would reflect just their listings as an output. I can create the individual templates of course but how do I "call" a specific search template from the search.cgi script? I want to place a link on their homepages that will enable users to search only that clients listings. We are using version 2.28. Thanks in advance.
|
|
|  |
 |

Benjamin
Staff

Feb 16, 2003, 11:19 AM
Post #2 of 5
(1968 views)
Shortcut
|
|
Re: [gfweb] custom search query templates
[In reply to]
|
Can't Post
|
|
Hi gfweb, What you have to do is hardcode a specific query to the search engine, with a few extra search parameters tacked on at the end, e.g.: http://www.yourdomain.com/path/to/search.cgi?search=1&template=_name_of_template.html&user_num=1 - search=1 tells the script it's supposed to perform a search (and not just draw the search query form) - templates=_name_of_template.html just specifies the template to use. (And make sure you've stored it in the /templates directory!) - user_num=1 says WHICH user to retrieve results for. To find out what the user number is for each realtor, go into Realty Manager and click on "User Manager". Here, roll the mouse over the "modify" button for the particular. You'll see that in the status bar at the bottom of the screen, you'll see something like: http://www.yourdomain.com/path/to/admin.cgi?userman_edit=2 the "2" corresponds to the number of the user. Post me back if you have any further questions! :-) Ben interactivetools.com
|
|
|  |
 |

gfweb
User
Feb 16, 2003, 1:37 PM
Post #3 of 5
(1956 views)
Shortcut
|
|
Re: [Benjamin] custom search query templates
[In reply to]
|
Can't Post
|
|
Hi Benjamin, I set up my hyperlink as follows <a href="http://www.myrealtywebsite.com/cgi/rm/exec/search.cgi?search=1&template=_search_query_bchap.html&user_num=11">search</a> but got "Template : Template cell 'not_found' is not defined!" as a reply. I obviously missed something on my custom template.
|
|
|  |
 |

Benjamin
Staff

Feb 16, 2003, 1:41 PM
Post #4 of 5
(1953 views)
Shortcut
|
|
Re: [gfweb] custom search query templates
[In reply to]
|
Can't Post
|
|
Yes, that template cell is called whenever there are no listings - and as such, it's required. Try adding something like this, somewhere in your page: <!-- templatecell : not_found --> <font face="arial" size=1><br></font> <table width=580 border=0 cellspacing=1 cellpadding=5> <tr> <td align=center valign=top bgcolor="#FFFFFF"> <font face="arial" size=3><b>Sorry, No listings were found that matched your search query.<br>Please try your search again.</b></font><br> </td> </tr> </table> <!-- /templatecell : not_found --> Ben interactivetools.com
|
|
|  |
 |

gfweb
User
Feb 17, 2003, 9:56 AM
Post #5 of 5
(1925 views)
Shortcut
|
Re: [Benjamin] custom search query templates
[In reply to]
|
Can't Post
|
|
Thanks Benjamin, works perfectly!!!! although I also had to add the image template cells from the query results page to get it to work properly.
|
|
|  |
|