| Server IP : 216.238.66.20 / Your IP : 216.73.216.51 Web Server : nginx/1.30.4 System : Linux woropds 5.15.0-187-generic #197-Ubuntu SMP Fri Jul 17 19:17:01 UTC 2026 x86_64 User : root ( 0) PHP Version : 8.2.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /var/www/sweetheart.mx/htdocs/wp-content/plugins/backwpup/components/form/ |
Upload File : |
<?php
use BackWPup\Utils\BackWPupHelpers;
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
/**
* @var string $name Unique name of the field to handle value when form is submitted to PHP.
* @var string $value Optional. The field value. Default: "".
* @var string $placeholder Optional. The field placeholder. Default: "".
* @var string $trigger Optional. The javascript class. Default: "".
*/
# Name
if (!isset($name)) {
throw new Exception("Attribute 'name' is required on Search field");
}
# Defaults
$placeholder = $placeholder ?? "";
$value = $value ?? "";
# JS actions
$trigger = isset($trigger) ? "js-backwpup-$trigger" : "";
?>
<label class="mb-4 px-4 flex items-center border border-grey-500 rounded font-title focus-within:border-secondary-base">
<div class="text-grey-700">
<?php BackWPupHelpers::component("icon", ["name" => "search", "size" => "small"]); ?>
</div>
<input type="text" class="<?php echo esc_attr( BackWPupHelpers::clsx( "input-special flex-auto", $trigger ) ); ?>" placeholder="<?php echo esc_attr( $placeholder ); ?>" name="<?php echo esc_attr( $name ); ?>" value="<?php echo esc_attr( $value ); ?>">
<button class="text-grey-700 text-base js-backwpup-clear-search hover:text-secondary-darker">✕</button>
</label>