johnrichardarmstrong
Forum Replies Created
-
Thanks for your very prompt response. I’m not sure that it solves the issue I am having though. I have tried to simplify my problem to help illustrate it better:
I have taken on board your points about formatting and where the return statement is placed but I am still getting the response (some whitespace followed by null).
“null”
My code looks like this:
add_filter('wpwhpro/run/actions/custom_action/return_args', 'SimpleFunction', 10, 3); function SimpleFunction($return_args, $identifier, $response_body){ if( $identifier === 'test-webhook-as-plugin' ){ $return_args = array( 'success' => true, 'msg' => 'The call was successful', 'data' => array() ); //wp_mail(myEmailAddress, 'function fired successfully', 'see subject'); } return $return_args; }As you can see, to test that the code was actually being run I had the wp_mail (now commented out) function send me an email which did arrive, showing that the code did run. I was wondering if there is something obvious I am missing. The webhook can be triggered using the following GET request:
https://findmytutoronline.com/?wpwhpro_action=receive-invoice-data&wpwhpro_api_key=xxxxxxxxxxxx&action=custom_action&wpwh_identifier=test-webhook-as-pluginMany thanks again; I do appreciate you efforts.
John
- This reply was modified 5 years, 8 months ago by Steven Stern (sterndata).
- This reply was modified 5 years, 8 months ago by Steven Stern (sterndata).
Forum: Plugins
In reply to: [Frontend Dashboard] Dropdown menus in Settings MenuThanks for your help. It worked in the end. The plugin “PayPal Webhooks for WordPress” was interfering with the way the menus were rendered.
Thanks again
John
Forum: Plugins
In reply to: [Frontend Dashboard] Creating Greyed Out Fieldsfantastic! It would really add a lot to what is already a fantastic plugin! Thank you lots.
- This reply was modified 5 years, 10 months ago by johnrichardarmstrong.
Forum: Plugins
In reply to: [Frontend Dashboard] Creating Greyed Out FieldsThank you for your quick response. Would this be easy to implement do you think? I envisage for each field in a form, having a tick-box labelled readonly? If ticked then on the live user form the field would have the “readonly=readonly” attribute.
Forum: Plugins
In reply to: [Frontend Dashboard] Creating Greyed Out FieldsIs see that the user_login input box in the html has the parameter readonly=readonly; Is it possible to set this parameter for other input boxes?