Changeset 35193 for trunk/www


Ignore:
Timestamp:
Mar 20, 2008, 9:08:37 AM (12 years ago)
Author:
eridius@…
Message:

Fix WHERE issue introduced in r35151 that broke the all ports listing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/www/ports.php

    r35168 r35193  
    104104            $criteria = "pl.portfile = p.name AND pl.platform = '" . mysql_real_escape_string($substr) . "'";
    105105        }
    106         $query = "SELECT DISTINCT $fields FROM $tables WHERE $criteria ORDER BY name";
     106        if ($criteria == "") {
     107            $where = "";
     108        } else {
     109            $where = "WHERE $criteria";
     110        }
     111        $query = "SELECT DISTINCT $fields FROM $tables $where ORDER BY name";
    107112        $result = mysql_query($query);
    108113        if ($result) {
Note: See TracChangeset for help on using the changeset viewer.