editable-submit button

editable-submit button

I am new to JQuery. I want to add an x-editable to my page and be able to catch the clicked event when the submit or cancel button is clicked. I had this code and it worked for a short period. But it doesn't work anymore. Can anyone spot the problem with my code below?

this._onEditCollabNameButtonClicked = function (sender) {

    $("#myEditable").editable({

        mode: "inline",

        inputclass: "input-large",

        unsavedclass: null,

        validate: function (value) {

            if ($.trim(value) == '') {

                return 'Please provide a name for it.';

            }

        }

    });

    $(".editable-submit").click(function () {


        $("#" + CollaborationWidget.Buttons.EDIT_COLLAB_NAME_ID).show();

    });

    $(".editable-cancel").click(function () {

        $("#" + CollaborationWidget.Buttons.EDIT_COLLAB_NAME_ID).show();

    });

    $("#" + CollaborationWidget.Buttons.EDIT_COLLAB_NAME_ID).hide();

    return false;

};