OK, here is a possible solution for you. You'll need to test it and make sure you don't get any wierd results with your data.
$sql = "SELECT * FROM tbl_Files ";
$sql .= "WHERE year LIKE '%$selyear'";
$sql .= "AND make LIKE '%$selmake'";
$sql .= "AND model LIKE '%$selmodel'";
$sql .= "AND engine LIKE '%$selengine'";
$sql .= "ORDER BY filename ASC";
What that is going to do is if anyone of those variables is empty, it will search for just '%' and that will match everything...the only thing to be careful for is a situation like this:
$selengin = "v6"
and you have data in your table where engine = "turbo-v6", the query I supplied will match that, because it has v6 at the end.
Hope that helps,
Matt Wade
codewalkers.com