Autofill confirmation

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
lamany77
User
Posts: 144

Autofill confirmation

Post by lamany77 »

hi all
i've field name : code_link (use for select item with auto fill)
and another field name : result_link...

i've set to auto fill and it works fine,
question is how to make a confirmation before autofill is update my result_link..
if confirmation is yes..then update result_link value...
if confirmation is no... then reset result_link value...

thank you..


Webmaster
User
Posts: 9425

Post by Webmaster »

For example, if you are working with the Add page, you can attach an event handler for the event 'autofill', e.g. in Startup Script

$("#x_code_link").on("autofill", function(e, args) {

//console.log(args); // Uncomment to view the arguments in browser console

// check args.data (value to fill the target), prompt for confirmation, and set args.cancel to true if answer is no

});


Post Reply