search feature old version cms builder 1.12

2 posts by 2 authors in: Forums > CMS Builder
Last Post: March 14, 2013   (RSS)

By biorn - March 13, 2013

we have a site using cms 1.12. the site is working fine and no issues. it is very customized and no need for any upgrades.

we are going to add a search feature and so far that works fine for one list (or sql tables), but not multiple on the same page.

we have  the following code on the result page:

<?php
require_once "D:/Inetpub/3dscanningtechnologies/cms3d/lib/viewer_functions.php";
$options = array(); // NOTE: see online documentation for more details on these options
$options['tableName'] = 'industrynews'; // (REQUIRED) MySQL tablename to list record from. Example: 'article';
$options['titleField'] = 'title'; // (optional) MySQL fieldname used in viewer url for search engines. Example: 'title' would display: viewer.php/article_title_here-123
$options['viewerUrl'] = 'industrynewsPage.php'; // (optional) URL of viewer page. Example: '/articles/view.php';
$options['perPage'] = '17'; // (optional) The number of records to display per page. Example: '5'; Defaults to 10.
$options['orderBy'] = 'featured_article DESC, date DESC, title'; // (optional) Fieldnames to sort by. Example: 'field1, field2 DESC, field3';
$options['pageNum'] = ''; // (optional) Page number of results to display. Example: '1'; Defaults to ?page=# value, or 1 if undefined
$options['where'] = ''; // (ADVANCED) Additional MySQL WHERE conditions. Example: 'fieldname = "value"'
$options['useSeoUrls'] = ''; // (ADVANCED) Set this to '1' for search engine friendly urls: view.php/123 instead of view.php?123 (not supported on all web servers)
list($listRows, $listDetails) = getListRows($options);
?>

this works all fine and no issues and it searches just fine.

However, we have several tables (not only the "industrynews"). how do we include the search to display results from multiple tables?

thanks,

biorn