Support Forums

Integrating custom search software

This is a discussion on Integrating custom search software within the Modules / Plugins / Modifications forums, part of the Developer Forums category; I am an experienced Ajax designer, but very, very new to 68 Classifieds. I have developed over the years a ...


Go Back   68 Classifieds Forums > Developer Forums > Modules / Plugins / Modifications

Reply
 
Thread Tools Display Modes
Old 02-05-2009, 12:01 AM   #1
Junior Member
 
Join Date: Feb 2009
Location: Santa Rosa, CA
Posts: 1
Rep Power: 0
calast is on a distinguished road
Default Integrating custom search software

I am an experienced Ajax designer, but very, very new to 68 Classifieds. I have developed over the years a custom finder object that allows users to enter complex search terms, which are then processed by an onClick listener to serialize what the user specified into XML. This is in turn sent to the server, where PHP code takes over. Its job is to turn the XML into a database query of varying complexity, depending on what the user specified.

I would like to integrate this into the system somehow as an alternative for my users. The issue is that the result set from the query ought to do something useful, like return a list of matching ads that can be displayed in the normal way. But I admit that I have no idea what a search result set is supposed to look like to this software package.

So my question is - can this even be done? And if so, where should I start looking to figure out how? I suspect this is well outside the range of what a typical user does, so it probably isn't documented. Any help would be greatly appreciated.
calast is offline   Reply With Quote
Old 02-05-2009, 08:58 AM   #2
curmudgeon
 
Join Date: Mar 2006
Posts: 5,413
Rep Power: 138
Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light
Default

The current search has no use for xml and 68C in general dosnt use it for anything(aside from the external.php file to build an rss feed), no real need.

That being said the curent default search form for 68C displays admin set fields to search including a category dropdown. If a category is selected and extra fields defined for that category that are set searchable will appear on the form.

Upon submit, All of these values are sent to the underlying script which calls the function getAllListings located in /includes/classes/kernel/Listings.php.

From there the values passed to it from the form are used to build a mysql query which collects ads from the database and they are put into an array. This array is assigned to the smarty template as a variable and the template itself does a foreach over the array displaying the ads for the user.

The getAllListings function is pretty complex and you may be able to do what you want but your going to have to sift through the function to learn exactly what it does and likely rebuild it to accept your input.
__________________
Larry

Knowledge learned is more valuable than knowledge given.
Lhotch is offline   Reply With Quote
Old 02-05-2009, 09:25 AM   #3
Staff
 
Join Date: Mar 2006
Location: New Jersey
Posts: 2,149
Rep Power: 68
John Snyder is a jewel in the rough
Default

To add to LHotch's comments, you might also look into using the module system to hook into the search results. There are several hooks there that you might be able to use, these are documented. You could also create your own query and link to it, just because it is there doesn't mean you have to use it
__________________
John
68C Staff

68C Downloads | Report a Bug | Knowledge Base
If you have a current support subscription, you can Submit a Support Ticket
John Snyder is offline   Reply With Quote
Reply

Thread Tools
Display Modes



All times are GMT -4. The time now is 10:16 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2011, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0