Diese Präsentation wurde erfolgreich gemeldet.
Die SlideShare-Präsentation wird heruntergeladen. ×

Contact Form 7 - Pflicht und Kür

Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Nächste SlideShare
Das Child-Theme-Dilemma
Das Child-Theme-Dilemma
Wird geladen in …3
×

Hier ansehen

1 von 19 Anzeige

Weitere Verwandte Inhalte

Weitere von Torsten Landsiedel (18)

Anzeige

Aktuellste (20)

Contact Form 7 - Pflicht und Kür

  1. 1. Contact Form 7 Pflicht und Kür WordCamp Cologne 2015 Torsten Landsiedel
  2. 2. Hallo! Torsten Landsiedel WordPress-Webworker Moderator im Supportforum Mitglied im Redaktionsteam de.w.org Translation Contributor und Editor Co-Orga WP Meetup Hamburg Co-Orga WordCamp Hamburg @zodiac1978
  3. 3. Pflicht Funktionen, die man kennen sollte
  4. 4. Barrierefreie Formulare BAD DEFAULT: <p>Your Name (required)<br /> [text* your-name] </p> <p>Your Email (required)<br /> [email* your-email] </p> <p>Subject<br /> [text your-subject] </p> <p>Your Message<br /> [textarea your-message] </p> <p>[submit "Send"]</p> http://blog.rrwd.nl/2014/03/01/how-to-set-up-an-accessible-form-using-contact-form-7-in-wordpress/
  5. 5. Barrierefreie Formulare BEST PRACTICE: [response] <label for="name">Name (required)</label> [text* your-name id:name] ... [submit "Submit"] https://wordpress.org/plugins/contact-form-7-accessible-defaults/
  6. 6. Nur Laden, wenn Formular genutzt add_filter( 'wpcf7_load_js', '__return_false' ); add_filter( 'wpcf7_load_css', '__return_false' ); function reregister_cf7_javascript() { if ( is_page( array( 1, ‘kontakt’ ) ) ) { if ( function_exists( 'wpcf7_enqueue_scripts' ) ) { wpcf7_enqueue_scripts(); } if ( function_exists( 'wpcf7_enqueue_styles' ) ) { wpcf7_enqueue_styles(); } } } add_action( 'wp_enqueue_scripts', 'reregister_cf7_javascript' ); http://contactform7.com/loading-javascript-and-stylesheet-only-when-it-is- necessary/
  7. 7. Kür Funktionen, die nicht jeder kennt
  8. 8. AGB gelesen und akzeptiert? [acceptance accept-this] AGB gelesen und akzeptiert http://contactform7.com/acceptance-checkbox/
  9. 9. Standardwerte setzen [text* your-name default:get default:post_meta default: user_display_name "Dein Name"] Von links nach rechts: GET-Variable gesetzt? Post-Meta definiert? Eingeloggter User, mit gesetzten Namen? Alles nicht der Fall? Dann nutze “Dein Name” als Standardwert. http://contactform7.com/getting-default-values-from-the-context/ http://contactform7.com/setting-default-values-to-the-logged-in-user/
  10. 10. Erfolgsseite on_sent_ok: "location = '/formular-erfolgreich-eingetragen/';" Nach erfolgreichem Absenden des Formular auf Extraseite weiterleiten.
  11. 11. HTML5-Input Types (date, etc.) /* Activate HTML5 fallback support See: http://contactform7.com/faq/does-contact-form-7-support-html5-input- types/ */ add_filter( 'wpcf7_support_html5_fallback', '__return_true' );
  12. 12. Min+Max Kombination von Datepicker und min:today
  13. 13. Big brother is watching you! Ein paar Informationen des User mitsenden: [_remote_ip] [_user_agent] [_url] [_date] [_time] http://contactform7.com/special-mail-tags/
  14. 14. Zugangsrechte Standard ist: alle können Lesen (außer der Abonnent). Gelöst über die capability. Änderbar per Konstante: define( 'WPCF7_ADMIN_READ_CAPABILITY', 'manage_options' ); Ebenso das Bearbeiten der Formulare. Standardmäßig Admin und Redakteur. So nur noch der Admin alleine: define( 'WPCF7_ADMIN_READ_WRITE_CAPABILITY', 'manage_options' );
  15. 15. Platzhalter [text your-name placeholder "Your name here"] http://contactform7.com/setting-placeholder-text/
  16. 16. Mail-Datenbanken Jede Mail über Contact Form 7 sichern: https://wordpress.org/plugins/flamingo/ https://wordpress.org/plugins/contact-form-7-to-database-extension/ https://wordpress.org/plugins/contact-form-7-integrations/ https://wordpress.org/plugins/contact-form-to-email/
  17. 17. CF7-Erweiterungen https://wordpress.org/plugins/tags/cf7 Anti-Spam: https://wordpress.org/plugins/wp-math-captcha/ https://wordpress.org/plugins/contact-form-7-honeypot/ Better UI/UX: https://wordpress.org/plugins/contact-form-7-style/ https://wordpress.org/plugins/contact-form-7-designer/ https://wordpress.org/plugins/contact-form-7-skins/ https://wordpress.org/plugins/cf7-mce/ https://wordpress.org/plugins/contact-form-7-success-page-redirects/
  18. 18. CF7-Erweiterungen https://wordpress.org/plugins/tags/cf7 Special cases: https://wordpress.org/plugins/ns-google-sheets-connector/ https://wordpress.org/plugins/wp-job-manager-contact-listing/ Shops https://wordpress.org/plugins/contact-form-7-paypal-add-on/ https://wordpress.org/plugins/process-automation/ Und noch viele mehr ...
  19. 19. Fragen? Danke!

×