noalyss-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Noalyss-commit] [noalyss] 40/73: Cosmetic : add button_magnifier for se


From: Dany De Bontridder
Subject: [Noalyss-commit] [noalyss] 40/73: Cosmetic : add button_magnifier for searching
Date: Fri, 28 May 2021 05:26:34 -0400 (EDT)

sparkyx pushed a commit to branch master
in repository noalyss.

commit 44360754651f7d42c1029509ee28b8501f42423e
Author: sparkyx <danydb@noalyss.eu>
AuthorDate: Sun Apr 25 23:42:28 2021 +0200

    Cosmetic : add button_magnifier for searching
---
 include/lib/icard.class.php       |  2 +-
 include/lib/icon_action.class.php | 14 ++++++++++++++
 2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/include/lib/icard.class.php b/include/lib/icard.class.php
index ed69aac..9152b33 100644
--- a/include/lib/icard.class.php
+++ b/include/lib/icard.class.php
@@ -580,7 +580,7 @@ class ICard extends HtmlInput
         $javascript=$a.' search_card(this);return false;';
         
         
-        $button=Icon_Action::icon_magnifier(uniqid(),$javascript);
+        $button=Icon_Action::button_magnifier(uniqid(),$javascript);
         return $button;
     }
 
diff --git a/include/lib/icon_action.class.php 
b/include/lib/icon_action.class.php
index 566a259..7344b2c 100644
--- a/include/lib/icon_action.class.php
+++ b/include/lib/icon_action.class.php
@@ -44,6 +44,20 @@ class Icon_Action
                 $id, $p_style, $p_javascript);
         return $r;
     }
+    /**
+     * Display a icon with a magnify glass
+     * @param string $id id of element
+     * @param string $p_javascript
+     * @param string $p_style optionnal HTML code
+     * @return type
+     */
+    static function button_magnifier($id, $p_javascript, $p_style="")
+    {
+        $r="";
+        $r.=sprintf('<input type="button"  id="%s" class=" smallbutton icon" 
style="%s" onclick="%s" value="&#xf50d;">',
+                $id, $p_style, $p_javascript);
+        return $r;
+    }
 
     /**
      * 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]