mirror of
https://github.com/vrana/adminer.git
synced 2025-08-08 07:36:44 +02:00
Use IS NULL operator for null value in where_link function
This commit is contained in:
@@ -302,7 +302,7 @@ function where_check($val) {
|
|||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
function where_link($i, $column, $value, $operator = "=") {
|
function where_link($i, $column, $value, $operator = "=") {
|
||||||
return "&where%5B$i%5D%5Bcol%5D=" . urlencode($column) . "&where%5B$i%5D%5Bop%5D=" . urlencode($operator) . "&where%5B$i%5D%5Bval%5D=" . urlencode($value);
|
return "&where%5B$i%5D%5Bcol%5D=" . urlencode($column) . "&where%5B$i%5D%5Bop%5D=" . urlencode((isset($value) ? $operator : "IS NULL")) . "&where%5B$i%5D%5Bval%5D=" . urlencode($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Set cookie valid for 1 month
|
/** Set cookie valid for 1 month
|
||||||
|
@@ -336,7 +336,7 @@ if (!$columns) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
foreach ($unique_array as $k => $v) {
|
foreach ($unique_array as $k => $v) {
|
||||||
$link .= h(where_link($i++, $k, $v, (isset($v) ? "=" : "IS NULL")));
|
$link .= h(where_link($i++, $k, $v));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user