Hey there, Awesome Customers!

Just a heads up: We'll be taking a breather to celebrate International Workers' Day (May 1st and 2nd - Wednesday and Thursday) and Orthodox Easter from Good Friday (May 3rd) through Easter Monday (May 6th). So, from May 1st to May 6th, our team will be off enjoying some well-deserved downtime.

During this time, our customer support will be running on a smaller crew, but don't worry! We'll still be around to help with any urgent matters, though it might take us a bit longer than usual to get back to you.

We'll be back in action at full throttle on May 7th (Tuesday), ready to tackle your questions and requests with gusto!

In the meantime, you can explore our documentation for Amelia and wpDataTables. You'll find loads of helpful resources, including articles and handy video tutorials on YouTube (Amelia's YouTube Channel and wpDataTables' YouTube Channel). These gems might just have the answers you're looking for while we're kicking back.

Thanks a bunch for your understanding and support!

Catch you on the flip side!

Warm regards,

TMS

Okay
  Public Ticket #3439093
Need code sample for validate after edit save
Closed

Comments

  • Karl R Englund started the conversation

    Do you have any sample code or reference materials with example of how to call code (PHP or other) after the save button is pressed during edit of a WPDataTable?

  •  1,689
    Miloš replied


    Hi Karl,

    Firstly, I would like to sincerely apologize for the delayed response as we have been experiencing an unusually high number of tickets. I am sorry that it has taken longer than usual to respond to your concern and your patience is highly appreciated.

    -

    If i understood, you would need something like a 'data validation' of an edited entry before it gets saved/stored in the table?

    This is not possible with our current built-in features,

    if you wish to see a built-in solution in the future,

    Please feel free to search on our suggestions page

     to see if someone may be already suggested this feature. If you can't see it, feel free to add your suggestion there,  and as more people vote, the feature will move higher on the priority list.

    You can certainly follow our changeLog page if you'd like ( it is also available in the plugin dashboard), where we state any changes/new features/bug fixes during updates;

    and our newsletter, so you're informed about new features, bug fixes, freebies, etc.

    -


    When it comes to a custom workaround, we don't have any example to show you for something similar to this specific use-case.

    We can only provide at least some advice that our developers sent us, and we hope this might help get  you started:

    In this file of our plugin:

    wp-content/plugins/wpdatatables/controllers/wdt_ajax_actions.php 

    around line 252, where the method for saving wdtSaveTableFrontend is, you can find these hooks:

    Actions:

    wpdatatables_before_frontend_edit_row

    wpdatatables_after_frontent_edit_row

    Filters:

    wpdatatables_filter_frontend_formdata

    wpdatatables_filter_formdata_before_save

    wpdatatables_query_before_save_frontend

    With those, a developer can manipulate the data which a user entered in the table. 

    This is as much as our developers can advise since using combinations and solutions which are not included in the built-in functions of the plugin require additional engagement, 

    and are not included in the provided support.

    I hope that helps.

    It probably can be done with some custom work, but our developers are very busy at the moment, working on some priority tasks and fixing bugs and issues with our plugins, so they won't be having the time for custom work in the near future.



    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables