diff options
| author | moehm | 2014-12-04 19:27:13 +0100 |
|---|---|---|
| committer | moehm | 2014-12-04 19:27:13 +0100 |
| commit | 649c27924e8e800994b7e10138a7c89b26eba5d7 (patch) | |
| tree | 29c616d971a366d7e7ebddf07845f1cfce8bc3e6 | |
| parent | bf3847219714d71e59bfa04569089ab52f852960 (diff) | |
| download | tools.iamfabulous.de-649c27924e8e800994b7e10138a7c89b26eba5d7.tar.gz | |
Clear input from button instead automatically.
| -rw-r--r-- | down/view/templ-index.php | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/down/view/templ-index.php b/down/view/templ-index.php index cc554e1..c6f1d44 100644 --- a/down/view/templ-index.php +++ b/down/view/templ-index.php @@ -32,6 +32,7 @@ <div class="form-group"> <label class="col-md-4 control-label" for="url">Check if up: </label> <div class="col-md-4"> + <div class="input-group"> <?php if ( isset($_REQUEST["url"]) && $_REQUEST["url"] != "" ){ ?> <input id="url" name="url" placeholder="kernel.org" class="form-control input-md" required="" type="text" <?php echo 'value="'.htmlentities($_REQUEST["url"]) . '"'; ?> autofocus> @@ -42,6 +43,10 @@ <?php } ?> + <span class="input-group-btn"> + <button type="button" class="btn btn-default addButton" title="Clean Input" onclick="clean('#url');">C</button> + </span> + </div> </div> </div> @@ -103,7 +108,6 @@ confirmButtonClass: button }); - $("#url").val(''); }, }); @@ -112,6 +116,10 @@ $(".fa-spinner").addClass("fa-spin"); + clean(id){ + $(id).val(''); + } + }; </script> <script defer src="../tools/static/sweet-alert.js"></script> |
