sealview
Forum Replies Created
Viewing 2 replies - 1 through 2 (of 2 total)
-
Forum: Plugins
In reply to: [Contact form 7 TO API + Basic Auth] Problems after updateHi,
I had the same problem.
I found a quick solution. I am not a WP guru, but the solution works for me.
It seams that with the CF7 5.5.3 the Post’s meta is called different, so this is what you have to do to work.Open the plug-in’s folder (wp-content/plugins/cf7-to-api/) go to “include” folder and open in editing mode the “class-cf7-api-admin.php”.
Search for the «wpcf7_integrations» function, it should be at line 146 and add in the beginning of the function the follow code (right before $wpcf7_[…] declarations):$wpcf7 = WPCF7_ContactForm::get_current(); $form_id = $wpcf7->id();Now you have to change the first 4 declaration from:
$wpcf7_api_data = $post->prop( 'wpcf7_api_data' ); $wpcf7_api_data_map = $post->prop( 'wpcf7_api_data_map' ); $wpcf7_api_data_template = $post->prop( 'template' ); $wpcf7_api_json_data_template = $post->prop( 'json_template' );With this:
$wpcf7_api_data = get_post_meta($form_id,'_wpcf7_api_data')[0]; $wpcf7_api_data_map = get_post_meta($form_id,'_wpcf7_api_data_map')[0]; $wpcf7_api_data_template = get_post_meta($form_id,'template'); $wpcf7_api_json_data_template = get_post_meta($form_id,'json_template');Now it should work fine!
Hope it helps!- This reply was modified 4 years, 3 months ago by sealview. Reason: more comprehensive
Forum: Plugins
In reply to: [Stella plugin] Adding Flags to Stella pluginHere’s an example, based on my two language website.
JSFiddleHope it helps ya.
Viewing 2 replies - 1 through 2 (of 2 total)