From 64d08544b29323dc86b19303fe21a4cddac0aa1b Mon Sep 17 00:00:00 2001 From: lmarcouiller Date: Fri, 22 Jan 2021 09:09:46 +0100 Subject: [PATCH] move of function showValueWithCopyPasteButton in function.lib.php --- htdocs/core/lib/functions.lib.php | 39 +++++++++++++++++++++++++++++++ htdocs/societe/card.php | 37 ----------------------------- 2 files changed, 39 insertions(+), 37 deletions(-) diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index c146f1f9a47..dcdff379cc0 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -9231,3 +9231,42 @@ function readfileLowMemory($fullpath_original_file_osencoded, $method = -1) fclose($handle2); } } + +/** + * Create a button to copy $valuetoprint in the clipboard + * @param string $valuetoprint the value to print + * @param string $spanid unique id for a span + * @param Translate $langs the $langs variable + * @return string the string to print for the button + */ +function showValueWithCopyAndPasteButton($valuetoprint, $spanid, $langs) +{ + $stringtoprint= ''; + $stringtoprint.= $valuetoprint .' '; + $stringtoprint.= ''; + $stringtoprint.=''; + $stringtoprint.=""; + return $stringtoprint; +} \ No newline at end of file diff --git a/htdocs/societe/card.php b/htdocs/societe/card.php index b25b7bf73b8..0014e4b8ebe 100644 --- a/htdocs/societe/card.php +++ b/htdocs/societe/card.php @@ -2939,43 +2939,6 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) include DOL_DOCUMENT_ROOT.'/core/tpl/card_presend.tpl.php'; } } -/** - * @param string $valuetoprint the value to print - * @param string $spanid unique id for a span - * @param Translate $langs the $langs variable - * @return string the string to print for the button - */ -function showValueWithCopyAndPasteButton($valuetoprint, $spanid, $langs) -{ - $stringtoprint= ''; - $stringtoprint.= $valuetoprint .' '; - $stringtoprint.= ''; - $stringtoprint.=''; - $stringtoprint.=""; - return $stringtoprint; -} // End of page llxFooter(); $db->close();