Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

jquery clear select 2

$('select2element').val(null).trigger("change")
Comment

jquery select clear options

$('#mySelect')
    .find('option')
    .remove()
    .end()
    .append('<option value="whatever">text</option>')
    .val('whatever')
;
Comment

reset select2 jquery | clear select2 option value

$("ClassOrIDName").trigger("change");
Comment

PREVIOUS NEXT
Code Example
Javascript :: js letters alphabet array 
Javascript :: disable click event jquery 
Javascript :: js get first space in string 
Javascript :: js queryselector names 
Javascript :: javascript disable enter key 
Javascript :: js date of yesterday 
Javascript :: jquery json decode 
Javascript :: js method string remove extra spaces 
Javascript :: wordpress echo admin ajax url 
Javascript :: js append element to body 
Javascript :: sequelize like search 
Javascript :: how to insalk react router with npm 
Javascript :: country code regex 
Javascript :: jquery remove option from select by value 
Javascript :: vibrate javascript 
Javascript :: get the first number of the integer in js 
Javascript :: jquery get all checked checkboxes 
Javascript :: session storage 
Javascript :: clz32() js 
Javascript :: onload javascript function call 
Javascript :: js get home url 
Javascript :: Factorial of Number in Javascript using Recursive call in javascript 
Javascript :: strip html tags javascript 
Javascript :: convert utc time to local time moment 
Javascript :: npm font awesome vue 
Javascript :: text to speech js 
Javascript :: image next src url 
Javascript :: eslint allow debugger 
Javascript :: js get hh mm ss 
Javascript :: react router dom 6 go back 
ADD CONTENT
Topic
Content
Source link
Name
1+6 =