Prestashop modules by QuickUpdate
Bringing e-commerce to the next level

EASY INSTALL
Modules install without additional software

15 DAYS RETURN
Refund for any unsolvable issues

SECURE PAYMENT
Pay securely through Paypal

DEDICATED SUPPORT
Our experts are here to help

[QUICKFIX] Bad category filter
Pages: [1]
  Print  
Author Topic: [QUICKFIX] Bad category filter  (Read 1897 times)
admin
Administrator
Full Member
*****
Offline Offline

Posts: 161


View Profile
« on: January 28, 2012, 05:14:57 AM »

Problem:

The category filter does not filter categories correctly in QuickUpdate v4.0

Solution:

Identify and replace the following function in the "database.php" file of QuickUpdate:

Code:
public function parseFilterValue($type, $value) {

$tt1 = str_replace(",",",|",$value);

$tt2 = str_replace(",","|,",$value);

$tt3 = str_replace(",",",|,",$value);

$tt4 = str_replace(",",",|,",$value);

$types = array("string" => "'%{$value}%'",

"date" => "'".date("Y-m-d",strtotime($value))."'",

"boolean" => ($value === true) ? "1" : "0",

"list" => "'(^({$tt1},))|((,{$tt2})$)|(,{$tt3},)|(^({$tt4})$)'"

);

return isset($types[$type]) ? $types[$type] : $value;

}
Logged
Pages: [1]
  Print  
 
Jump to:  

Cart  

(empty)