Commit:    4c0378e70421cc8294f7bf4c28f00f4420f0dc18
Author:    Sobak <[email protected]>         Sun, 4 Dec 2016 07:18:50 +0100
Parents:   83bfdbe46cba035a6816e98798a244b37167e715
Branches:  master

Link:       
http://git.php.net/?p=web/master.git;a=commitdiff;h=4c0378e70421cc8294f7bf4c28f00f4420f0dc18

Log:
Use native search form supported by web-shared

Changed paths:
  M  include/functions.inc
  M  manage/user-notes.php


Diff:
diff --git a/include/functions.inc b/include/functions.inc
index e396a22..dfac701 100644
--- a/include/functions.inc
+++ b/include/functions.inc
@@ -39,6 +39,9 @@ function head($title="", $config = array()) {
     if (strstr($_SERVER["SCRIPT_FILENAME"], "event.php")) {
         $SEARCH = array("method" => "get", "action" => "/manage/event.php", 
"placeholder" => "Search Events", "name" => "search");
     }
+    if (strstr($_SERVER["SCRIPT_FILENAME"], "user-notes.php")) {
+        $SEARCH = array("method" => "get", "action" => 
"/manage/user-notes.php", "placeholder" => "Search notes (keyword or ID)", 
"name" => "keyword");
+    }
     if (isset($_SESSION['credentials'])) {
         array_unshift($LINKS, array("href" => "/manage/users.php?username=" . 
$_SESSION["credentials"][0], "text" => "My Profile"));
         $LINKS[] = array("href" => "/login.php?action=logout", "text" => 
"Logout");
diff --git a/manage/user-notes.php b/manage/user-notes.php
index 170f9e6..35ea205 100644
--- a/manage/user-notes.php
+++ b/manage/user-notes.php
@@ -421,21 +421,8 @@ if (!$action) {
 <?php
   }
 ?>
-<p>Search the notes table.</p>
-<form method="post" action="<?= PHP_SELF ?>">
-<table>
- <tr>   
-  <th align="right">Keyword or ID:</th>
-  <td><input type="text" name="keyword" value="<?php echo 
(isset($_REQUEST['keyword']) ? hscr($_REQUEST['keyword']) : ''); ?>" size="10" 
maxlength="32" /></td>
- </tr>
- <tr> 
-  <td align="center" colspan="2">
-    <input type="submit" value="Search" />
-  </td>
- </tr>
-</table>
-</form>
 
+<h2>Menu</h2>
 <p><a href="<?= PHP_SELF ?>?action=mass">Mass change of sections</a></p>
 <p><a href="<?= PHP_SELF ?>?view=notes&type=0">View last 10 notes</a></p>
 <p><a href="<?= PHP_SELF ?>?view=notes&type=1">View first 10 notes</a></p>


--
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to