Unique Items SQL fix. genDocs uniqueitems.html table fix.

This commit is contained in:
color.diff=auto 2022-03-19 16:58:32 -06:00
parent 6db4dc4b5b
commit e19b3ef034
2 changed files with 7 additions and 4 deletions

View File

@ -136,8 +136,9 @@ WHERE `type` IS NOT NULL AND uniqueitems.`code`= $table.`code` AND $table.`code`
*/
if ($cmd == 'search') {
$search = $_GET['search'];
$sql = "SELECT * FROM uniqueitems WHERE `index` LIKE '%?%' OR code LIKE '%?%' AND enabled=1 ORDER BY `index`";
$res = PDO_FetchAll($sql,[$search, $search]);
$sql = "SELECT * FROM uniqueitems WHERE `index` LIKE '%$search%' OR code LIKE '%$search%' AND enabled=1 ORDER BY `index`";
$res = PDO_FetchAll($sql);
$html = '';
foreach ($res as $r) {
if ($sort == 'index') {

View File

@ -398,9 +398,11 @@ EOT;
echo $itemBoxBottom;
ob_flush();
$htmlFinal .= $props . $itemBoxBottom . $tableBottom;
$htmlFinal .= $props . $itemBoxBottom;
}// end loop
$htmlFinal .= $tableBottom;
echo $htmlbottom;
$htmlFinal .= $htmlbottom;