How to make the analog of SP.UI.ModalDialog.showModalDialog function, but render to specific div?
I need to render EditForm to div on page and set callback function. Something like SP.UI.ModalDialog.showModalDialog but show EditForm in specific div, not in pop-up.
var ShowForm = function () {
var options = {};
options.url = 'mywebUrl/Lists/myList/EditForm.aspx?ID=1';
options.dialogReturnValueCallback =
function (dialogResult, returnValue) {
console.log({ dialogResult: dialogResult, returnValue: returnValue });
}
// render form to popup div
SP.UI.ModalDialog.showModalDialog(options);
// needed something like this
SP.UI.ModalDialog.showInSpecificDiv(options, 'divId');
}