Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

ajax form submit without form tag

$(document).on('click', '#myButton', function(){  
    $.ajax({
        url: "insert.php",
        method: "post",
        data:{
            text: $('.text-value').val()
        },    
        dataType:"text",
        success:function(data){
            alert('Successfully')
        }
    })
})
Comment

PREVIOUS NEXT
Code Example
Javascript :: for each array javascript 
Javascript :: append to map javascript 
Javascript :: Download Node Module With NPM 
Javascript :: for of mdn 
Javascript :: datepicker min max date 
Javascript :: react router how to send data 
Javascript :: react eslint prettier 
Javascript :: backbone js cdn 
Javascript :: how to convert an array into single quote strings 
Javascript :: string length in javascript 
Javascript :: how to use a regex expression in kibana query 
Javascript :: prevent duplicate entries in javascript array 
Javascript :: set selected option jquery 
Javascript :: js binary 
Javascript :: jquery select option value selected 
Javascript :: javascript detectar la pagina 
Javascript :: javascript button click event 
Javascript :: javascript string concat vs + 
Javascript :: js string interpolation 
Javascript :: get second element with a class jquery 
Javascript :: read json file into array javascript 
Javascript :: classic asp get json from url 
Javascript :: anjular js 
Javascript :: javascript beginner 
Javascript :: Nestjs download 
Javascript :: prev props 
Javascript :: difference between undefined and null javascript 
Javascript :: dayjs after 
Javascript :: object copy in javascript 
Javascript :: change image onclick js 
ADD CONTENT
Topic
Content
Source link
Name
4+3 =