-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Email fields and date customization #37
Comments
Hi, The date is passed to the mail template at the following location and use RFC 2822 format. You coud change the format to what you prefer.
The ideal would be a general full-featured and localized format by default (pour avoir j/m/a en français par exemple), and in a second step maybe a config option to customize the format if needed. Feel free to make a PR if you can. Every fields are shown in the mail by default. The fields are passed to the mail template at the following lines, you may want to condition that based on the field type for example. p01contact/p01-contact/src/P01contact_Form.php Lines 358 to 359 in 1876bc4
The not translated fields is a bug. Could you test the patch #38 and report there for this subject ? |
Hi ! For the captcha you should add a condition as indicated in my previous message. p01contact/p01-contact/src/P01contact_Field.php Lines 297 to 299 in 1876bc4
Note that ideally the mail templating would be fully templated trough Twig to allow a simpler mail customization, but that's not a common request for now. Would love a PR though. |
Comme indiqué précédemment :
C'est à dire quelque chose comme : foreach ($this->fields as $field) {
if ($field->type != 'captcha') {
$tpl_data->fields .= $field->htmlMail();
} N'hésitez pas à créer une issue séparée pour une demande de feature de type "add an option to exclude fields by type in mail output" si ça vous semble pertinent. |
it's so good !!! Merci beaucoup !!! Le recaptcha Google fonctionne a merveille en plus.. j'ai rajouté les lignes suivantes dans le style.ccs de votre plugin pour que le recaptcha soit responsive... .g-recaptcha { le résultat final ici :+1 : |
Parfait 👍 Je n'inclue pas les hacks pour corriger les dimensions du recaptcha parce que les valeurs dépendent de chaque thème. Pensez néanmoins que vous pouvez inscrire votre règle dans une media query pour limiter son effet uniquement à la largeur d'écran appropriée. @media screen and (max-width: 455px) { |
Hi
how to delete this fields in the email ?
(text, Required) #0
(Required) #1
(textarea, Required) #3
can i change the date in the email like this ?
DD MM YY,HH:MM:SS instead of Fri, 05 Oct 2018 01:10:34 +0200
Where can i translate the fields in french in the mail ?
name, subject
thanks
The text was updated successfully, but these errors were encountered: