How can I hook forms to my custom plugin?


I’m creating a plugin that does API requests. I want to create forms using wordpress editor, elementor or WPforms so that when a user submits the form, the plugin receives each value in a form as a variable, does API request, then return the result.

my current plugin looks like that

   function APIcall($param1, $param2){
    // body of the API call
    return $res;
   // Add shortcodes
   add_shortcode( 'myplugin_testAPI','APIcall') ;
, , , roma salah 4 years 2020-07-21T03:10:31-05:00 0 Answers 37 views 0

Leave an answer