This will help lots of you - How to use hidden features to do advanced search prior to DataBridge being MySQLi ready
Got this information from a Premier support call with Ray and I am making this available as I know it will help others. I am sure most of you can follow this but if not make sure a POST is done to the page using form field keyword_search. I have included a recordset and a the search code for the recordset. The search code is searching the database fields products.itemnumber", "products.supplieritemnumber", "products.description", "products.german_description", "products.supplier
Make sure your rsobj.php file is at least version 2.18 or above as I have tested on this.
<?php if(!empty($_POST['keyword_search'])) {
$keywords = htmlentities(trim($_POST['keyword_search']));
$_SESSION['keywords'] = $keywords;
} ?>
<?php
$searchrs_products_WADbSearch1 = new WA_MySQLi_Search("rs_products","");
if (isset($_SESSION["keywords"])) {
$searchrs_products_WADbSearch1->clearSearch();
$searchrs_products_WADbSearch1->setSearch(array("type"=>"k", "comparison"=>"like", "join"=>"and", "and"=>" ", "or"=>", ", "end_encap"=>"'", "start_encap"=>"'"),array("products.itemnumber", "products.supplieritemnumber", "products.description", "products.german_description", "products.supplier"),"c",$_SESSION["keywords"]);
}
?>
<?php
$rs_products = new WA_MySQLi_RS("rs_products",$dmbc_database,50);
$rs_products->setQuery("SELECT products.itemnumber, products.description, products.visible, products.selling_quantity, products.price, products.stock, products.packed, products.pending_online_orders, special_prices.price AS special_price FROM products LEFT OUTER JOIN special_prices ON products.itemnumber = special_prices.itemnumber AND special_prices.userdetails_id = ? WHERE visible = 1 ORDER BY description ASC");
$rs_products->bindParam("i", "".($rs_customer->getColumnVal("id")) ."", "-1"); //colname
$rs_products->execute();
?>