rocklobster-in / contact-form-7 Goto Github PK
View Code? Open in Web Editor NEWContact Form 7 - Just another contact form plugin for WordPress.
License: Other
Contact Form 7 - Just another contact form plugin for WordPress.
License: Other
The wpcf7_ajax_json_echo
and wpcf7_ajax_onload
filter hooks used in includes/rest-api.php have a very old origin (WP REST API didn't exist at the time) and now they sound weird and too different from what they are in reality.
So, let's rename them as:
wpcf7_ajax_json_echo
=> wpcf7_feedback_response
wpcf7_ajax_onload
=> wpcf7_refill_response
Keep old hooks available for backward compatibility.
To make it consistent with apply_filters( 'wpcf7_special_mail_tags' )
in includes/mail.php.
WPCF7_VERSION
constant to 5.1.7 in wp-contact-form-7.phpAlso doing_it_wrong notice for the cases the $mail_tag
isn't given and comments that clarify the arguments are necessary.
When providing a form-tag field with a URL, the server makes a DNS query to that URL.
A form with the following form-tag:
[text* textfield akismet:author placeholder "ABC"]
If I enter an URL (http://www.example.org) in the input field "textfield" the server makes a DNS query for www.example.org. Why is that? This doesn't feel like something the plugin should do but when I'm looking for a cause I can't find anything else causing this to happen.
I've tried to locate where in the plugin code this would occur but can't find anything that would cause this behavior. I want to make sure if this is an issue with the plugin.
WPCF7_VERSION
constant in wp-contact-form-7.php to 5.2.2Currently it is affected by PHP timezone.
If it's missing you'll see a PHP notice like this:
PHP Notice: register_rest_route was called <strong>incorrectly</strong>. The REST API route definition for <code>contact-form-7/v1/contact-forms/(?P<id>\d+)/feedback</code> is missing the required <code>permission_callback</code> argument. For REST API routes that are intended to be public, use <code>__return_true</code> as the permission callback.
For details about permission_callback
, see the REST API Handbook.
Instead the mail-tag appears as-is.
WPCF7_VERSION
constant in wp-contact-form-7.php to 5.2.1We need that code at: wp-content/plugins/contact-form-7/modules/recaptcha.php, line 78 described here: https://wordpress.org/support/topic/error-grecaptcha-execute-is-not-a-function/#post-12658099
In Flamingo 2.2, the id
property of Flamingo_Contact
and Flamingo_Inbound_Message
objects has become a private property, and id()
is recommended to use as an alternative.
Role is unchangeable during a play, and all the men and women are merely players.
The latest release (5.2) is returning an empty response alert field (with red border) in our Avada theme
<div class="fusion-alert alert custom alert-custom fusion-alert-center wpcf7-response-output fusion-alert-capitalize alert-dismissable" style="border-width:1px;"><button type="button" class="close toggle-alert" data-dismiss="alert" aria-hidden="true">ร</button><div class="fusion-alert-content-wrapper"><span class="fusion-alert-content"></span></div></div>
This is not displayed after we rolled back to the (5.19) previous release.
There have been many updates since the last time I modified the module.
https://v3.developer.constantcontact.com/api_guide/release_notes.html
Use PHP time()
instead.
See https://make.wordpress.org/core/2019/09/23/date-time-improvements-wp-5-3/
WordPress 5.4.2 has introduced a new filter hook that just works as the existing set-screen-option
hook as part of security enhancement. This change also causes a minor issue that Number of items per page in the Screen Options is not saved. To fix the issue, support both of the set_screen_option_{$option}
and set-screen-option
hooks. The filter registration for the set-screen-option
hook will become unnecessary when the required WP version rises to 5.4.
As WPCF7_FormTag::get_option()
returns false when the option is not set.
Related support topic: Bug with RTL languages on input fields with numbers and spaces
Code-style input like URL, email or telephone number should be displayed in Left-to-Right direction. This is true even in languages that are written in Right-to-Left direction like Hebrew or Arabic.
This is not a problem in most cases because the CSS stylesheet used on the site applies appropriate direction
style rules, but some WordPress themes don't care about it. It is safer to set such rules in the plugin's stylesheet by default.
Based on a request posted in the support forum.
For example, if you have modules/recaptcha/recaptcha.php, the mod file is loaded preferentially. This makes it possible to have modules of more complex structure.
Just converting this wp.org forum thread into an issue.
Some people have already written Contact Form 7 blocks (e.g. this one), which should be easy to add to your plugin. Given WordPress core's growing emphasis on blocks, doing this becomes more and more needed every day.
Filters hooked to wpcf7_mail_tag_replaced
and wpcf7_mail_tag_replaced_{$type}
are not applied when get_posted_data()
returns null. This is unintended.
Related topic: https://wordpress.org/support/topic/accessibility-alert-problem/
Use DOM events instead.
Improve the telephone number pattern in wpcf7_is_tel()
.
At the moment Contact Form 7 loads Scripts & Styles on every page load on the front end. Realistically the contact form is only used on a few pages.
I would suggest loading the scripts and styles only on pages where the shortcode is included.
WordPress provided two functions to include a script / style:
wp_register_script
and wp_enqueue_script
wp_register_style
and wp_enqueue_style
The register
function just register the script / style and does not load it on the frontend. If you later call enqueue with just the same handle, it will load the script / style on the frontend.
I would suggest changing all enqueue
here: https://github.com/takayukister/contact-form-7/blob/master/includes/controller.php to register
and call wp_enqueue_script( 'contact-form-7' )
and wp_enqueue_style( 'contact-form-7' )
if the shortcode is included: https://github.com/takayukister/contact-form-7/blob/master/includes/contact-form-functions.php#L93
It's no problem to run wp_enqueue_script
with the handle multiple times and works great in the shortcode function.
WPCF7_REQUIRED_WP_VERSION
constant in wp-contact-form-7.php to 5.3WPCF7_VERSION
constant in wp-contact-form-7.php to 5.2I used Version 5.2.1 and it produced an error:
PHP Fatal error: Uncaught Error: Call to a member function to_array() on null in ... .../public_html/wp-content/plugins/contact-form-7/includes/rest-api.php:397
Would you please have a look?
Thanks
WPCF7_ContactForm::additional_setting()
returns an array. It would be useful to have a shortcut method that returns the first item of the array.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.