Rakesh February 2016

How to implement call back function using editable plugin in Jquery

I am using this editable plugin to edit of rows and update data into database.After updating data into database , I have to get success message using call back function. Please suggest prefect solution to call other function using this plugin.

$(function () {
        var url = $BaseUrl + "/abc/abc/ItemsList";
        $('.txt-editable').editable(url,CallBackFunction, {
            onblur: function (value) {
                this.reset(value);
                $(this).html(value);
                return (value);

            },
            width: 90,
            id: 'element_id',
            value: 'value'
        });
    });


function CallBackFunction(){

  alert("Success Message");
});

Answers


Ashish Parmar February 2016

$('#id').editable({
        type:'text',
        url: 'test/edit/1',
        source: source,
        success:function(response, newValue)
        {
	callfunction();
	var data = JSON.parse(response);
        },
	send: 'always',
	validate: function(value) 
	{
	}
 });

Post Status

Asked in February 2016
Viewed 2,413 times
Voted 11
Answered 1 times

Search




Leave an answer