onblur

    0熱度

    2回答

    我有以下功能,將簡單地清除模糊輸入。我正在使用角度材質,而且我正在創建一個指令,以便在我希望發生這種情況時添加。 function clearTextOnBlurLink(scope, element, attrs, controller) { $timeout(function() { var input = element.find('input');

    1熱度

    1回答

    Phone:<br> <input type="text" id="phone" name="phone" placeholder="Please enter your phone number"> The input box looks like this to begin with On click/focus, it looks like this 在鍵入數字值,下劃線應該得到更換或數

    0熱度

    1回答

    困難我真的很新的JavaScript/jQuery和我有困難的時候理解以下thisquery事件: 我在頁面的頭部加載我的腳本。 我有一個輸入的形式有點像這樣... <input id='registeremail' type='email; name='email' onblur=checkemail() > <button id='btn1'>Hello</button> 在上述情況下

    -1熱度

    1回答

    我在輸入上綁定了模糊。在模糊處,我想使用$(this)並檢測此輸入。有沒有辦法做到這一點? <input data-john="x" data-doe="false"> $('[data-john=x]:not([data-doe=true])').blur(function() { console.log($(this)) }) 在此示例中,$(this)正在返回Window

    1熱度

    2回答

    我有,我想格式化的onblur輸入字段值,這裏是我的代碼如下所示: 組件: <Input onBlur={this.formatEndpoint} /> 功能: formatEndpoint() { let endpoint = this.state.inputEndpoint; endpoint = endpoint.replace(/\s/g, '

    0熱度

    1回答

    我想添加onfocus/onblur事件到一個窗體,但不知何故我沒有得到它的工作。我認爲這與逃避報價有關,但我嘗試了幾種方法,但都沒有成功。我的代碼是這樣的:在你的onblur串 echo '<input type="password" id="'.$field->name.'" name="'.$field->name.'" size="30" class="inputbox" placehol

    0熱度

    1回答

    我正在使用模糊事件來觸發JS警報。如果我在輸入框中單擊我要調用的事件,然後不輸入任何內容,則單擊瀏覽器上的新選項卡按鈕或更改選項卡等,由於輸入框上的模糊效果,會觸發警報。但即使點擊OK,警報也不會消失。但是,如果我在同一頁面或瀏覽器選項卡內的任意位置點擊,則不會發生這種情況。然後,單擊確定按鈕關閉警報框。點擊一個新的標籤等,需要的是因爲用戶可能需要將數據從別的地方複製在輸入框中 的HTML <in

    -1熱度

    2回答

    我一直試圖改變一個textarea的邊框顏色焦點時,但它沒有做任何事情,即使我只是試圖提醒一些事情。 這是到目前爲止,我已經試過的方法: 第一: $('#idname').on('blur', function() { alert(1); }); 第二: document.getElementById('idname').onblur() = function() { a

    0熱度

    1回答

    我知道很多相關的問題到目前爲止已被問到,但我找不到真正解決我的問題。 從來就得到了相同的形式,從我的最後一個問題 - body { background-color: black; } .input-icon{ float:left; } <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.

    0熱度

    2回答

    我的形式有少量字段中,用戶可以在這樣一個 <input name='extracost' type='text' size='25' id='extracost' value='$extracost' onChange='calculate();' > 問題增加值是與的onblur或只的onChange「似乎」工作一次。如果元素extracost以0或null開始,例如,如果我將它的形式更改爲