summaryrefslogtreecommitdiff
path: root/modules/search/search.module
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2003-05-13 18:36:38 +0000
committerDries Buytaert <dries@buytaert.net>2003-05-13 18:36:38 +0000
commitc2d2fb73095a32394dd95e72421aec49fa2cd6f6 (patch)
tree5d2d92a31480405b8c10c3b85927049238528242 /modules/search/search.module
parent13ffd8956826fec3cd9978edf73ef67d9eb8d46e (diff)
downloadbrdo-c2d2fb73095a32394dd95e72421aec49fa2cd6f6.tar.gz
brdo-c2d2fb73095a32394dd95e72421aec49fa2cd6f6.tar.bz2
- Fixed a typo in the PostgreSQL database scheme. Patch by Michael Frankowski.
- Fixed a typo in the MSSQL database scheme. Patch by Michael Frankowski. - Removed dependency on "register_globals = on"! Patches by Michael Frankowski. Notes: + Updated the patches to use $foo["bar"] instead of $foo['bar']. + Updated the INSTALL and CHANGELOG files as well. - Tiny improvement to the "./scripts/code-clean.sh" script.
Diffstat (limited to 'modules/search/search.module')
-rw-r--r--modules/search/search.module11
1 files changed, 6 insertions, 5 deletions
diff --git a/modules/search/search.module b/modules/search/search.module
index c87372241..e680e2f1c 100644
--- a/modules/search/search.module
+++ b/modules/search/search.module
@@ -51,7 +51,7 @@ function search_settings() {
*
*/
function search_admin() {
- global $op;
+ $op = $_POST["op"];
// Only allow people with sufficient access.
if (user_access("administer search")) {
@@ -92,7 +92,6 @@ function search_cron() {
* explanation of array items
*/
function do_search($search_array) {
- global $PHP_SELF;
$keys = strtolower($search_array["keys"]);
$type = $search_array["type"];
@@ -167,10 +166,10 @@ function do_search($search_array) {
$count = $value["count"];
switch ($type) {
case "node":
- $find[$i++] = array("count" => $count, "title" => $title, "link" => (strstr($PHP_SELF, "admin") ? url("admin/node/edit/$lno") : url("node/view/$lno")), "user" => $name, "date" => $created, "keywords" => implode("|", $words));
+ $find[$i++] = array("count" => $count, "title" => $title, "link" => (strstr($_SERVER["PHP_SELF"], "admin") ? url("admin/node/edit/$lno") : url("node/view/$lno")), "user" => $name, "date" => $created, "keywords" => implode("|", $words));
break;
case "comment":
- $find[$i++] = array("count" => $count, "title" => $title, "link" => (strstr($PHP_SELF, "admin") ? url("admin/comment/edit/$lno") : url("node/view/$nid#$lno")), "user" => $name, "date" => $created, "keywords" => implode("|", $words));
+ $find[$i++] = array("count" => $count, "title" => $title, "link" => (strstr($_SERVER["PHP_SELF"], "admin") ? url("admin/comment/edit/$lno") : url("node/view/$nid#$lno")), "user" => $name, "date" => $created, "keywords" => implode("|", $words));
break;
}
}
@@ -306,7 +305,9 @@ function search_save($edit) {
}
function search_view($keys = NULL) {
- global $edit, $type;
+ global $type;
+
+ $edit = $_POST["edit"];
if (user_access("search content")) {
// Construct the search form: