Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.
Session:                            Meine ersten 12                            Monate als                            Plugi...
Beispiel DECKERWEB  Erstes Plugin live am 1. Juli 2011  Seitdem insgesamt 26 Plugins  Bis gestern 183.096 Downloads! - DAN...
Beispiel DECKERWEB                                                   ?  Ursachen:      Wollte tiefer in WP-Materie eindrin...
Beispiel DECKERWEB  Sehr viele Downloads & Nutzer - unerwartet!  Viel positives Feedback, einige Kritik!  2 Kollaboratione...
?Ziele  Reizvolle Aufgabe?  Lernen, weiterbilden, ausprobieren...  Wissen teilen!  Lösungen teilen!  Reputation verbessern...
!Lieber sein lassen, falls...  ...man gar keine Zeit für Support hat  ...nicht kritikfähig  ...“SVN“ gar nicht geht :)  .....
Grundkonzept  Eigentliche Funktionalität und Typ des Plugins     Eigenständiges Plugin?     Plugin-Plugin?     Theme-Plugi...
Vorbereitung - Aufbau  Hauptdatei mit Plugin-Kopf (Header, Meta, Lizenz)  Funktionen?  Klasse - Methoden?  Variablen  Kons...
(Datei-) Organisation  Klare Ordnung aller Dateien/ Assets  Saubere Benennung aller Dateien  Alle benötigten Dateien/ Bibl...
Grundprinzipien I  Alles mit Präfix bitte! //Funktionen:                               Bewährt: function ddw_bptb_init() {...
Grundprinzipien II  Code nur laden, wenn er gebraucht wird!     is_admin(), is_multisite(), is_network_admin() usw.      C...
Modulare Plugins      „Extensible, or modular code, is code that can be modified,      interacted with, added to, or manip...
Modulare Plugins                                               Know                                                       ...
Modulare Plugins                              WordPress                                             Gravity Forms         ...
Sicherheit  ESCAPE-Funktionen (HTML, Attribute, URLs)  SANITIZING-Funktionen - Benutzerein- undAusgaben absichern („heilen...
Coding Standards  Danke, Gary Jones! (@GaryJ)  Ohne „Regeln“ geht es auch hier nicht!Siehe: „Core Contributor Handbook“PHP...
Coding Standards  Lesbar  Verstehbar  Erweiterbar  Transportierbar  TeamarbeitDavid Decker · deckerweb.de · WP Camp 2012
Best Practices  Plugin: Modular arbeiten (Know your hooks :)  Titel/ Slug bei WordPress.org checken!  readme.txt Validator...
Wichtige Werkzeuge:  define( WP_DEBUG, true ); (wp-config.php)  Testen! Testen! Testen!     Am besten auf einer live-Umgeb...
Plugin live, was nun?  Downloads, Downloads, Downloads...  Support, Support, Support!  Updates, Updates, Updates... (Bugs,...
Würde ich es wieder tun?  JA, auf jeden Fall! ;-)  Unverzichtbare (Code-) Erkenntnisse und(menschliche) Erfahrungen!  In e...
readme.txt Validator:           http://wordpress.org/extend/plugins/about/validator/David Decker · deckerweb.de · WP Camp ...
SVN - Subversion:                           http://wordpress.org/extend/plugins/about/svn/David Decker · deckerweb.de · WP...
Verwendete Quellen: http://wordpress.org/extend/plugins/about/ (Dev Center) http://wordpress.org/extend/plugins/about/faq/...
Danke! Fragen jetzt! Folien unter:           deckerweb.de/wpcamp2012                         plus: slideshare.net/deckerwe...
/** Call for break and add next session */add_action( wpcamp_berlin_2012, wpc_next_session_planning )function wpc_next_ses...
Nächste SlideShare
Wird geladen in …5
×

Meine ersten 12 Monate als Plugin-Entwickler für WordPress - WP Camp 2012 Berlin

2.678 Aufrufe

Veröffentlicht am

Meine Erfahrungen mit dem Erstellen von Plugins für WordPress - was habe ich gelernt, worauf kommt es an? -- Hooks & Filter, Coding Standards, etc. -- ein bisschen aus dem Nähkästchen geplaudert. Vielleicht hilfreich für alle, die auch bei WordPress.org Plugins einstellen wollen, oder sich überhaupt mal an diese Materie heranwagen wollen...

Veröffentlicht in: Technologie
  • DOWNLOAD THE BOOK INTO AVAILABLE FORMAT (New Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://urlzs.com/UABbn } ......................................................................................................................... Download Full EPUB Ebook here { https://urlzs.com/UABbn } ......................................................................................................................... Download Full doc Ebook here { https://urlzs.com/UABbn } ......................................................................................................................... Download PDF EBOOK here { https://urlzs.com/UABbn } ......................................................................................................................... Download EPUB Ebook here { https://urlzs.com/UABbn } ......................................................................................................................... Download doc Ebook here { https://urlzs.com/UABbn } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THE can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THE is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBOOK .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, CookBOOK, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, EBOOK, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THE Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THE the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THE Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Antworten 
    Sind Sie sicher, dass Sie …  Ja  Nein
    Ihre Nachricht erscheint hier
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Antworten 
    Sind Sie sicher, dass Sie …  Ja  Nein
    Ihre Nachricht erscheint hier
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Antworten 
    Sind Sie sicher, dass Sie …  Ja  Nein
    Ihre Nachricht erscheint hier
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Antworten 
    Sind Sie sicher, dass Sie …  Ja  Nein
    Ihre Nachricht erscheint hier
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Antworten 
    Sind Sie sicher, dass Sie …  Ja  Nein
    Ihre Nachricht erscheint hier

Meine ersten 12 Monate als Plugin-Entwickler für WordPress - WP Camp 2012 Berlin

  1. 1. Session: Meine ersten 12 Monate als Plugin-Entwickler für WordPressDavid Decker · deckerweb.de · WP Camp 2012
  2. 2. Beispiel DECKERWEB Erstes Plugin live am 1. Juli 2011 Seitdem insgesamt 26 Plugins Bis gestern 183.096 Downloads! - DANKE :) Plugins nach Einsatzgebiet: WordPress generell: 2 bbPress 2.x: 3 Genesis Framework: 9 BuddyPress: 1 WooCommerce: 3 Easy Digital Downloads: 2 Jigoshop: 2 Gravity Forms: 1 Thesis, Xtreme One, iThemes: je 1David Decker · deckerweb.de · WP Camp 2012
  3. 3. Beispiel DECKERWEB ? Ursachen: Wollte tiefer in WP-Materie eindringen Hatte einige Ideen für Mini-Plugins Konkreter Anlass: Anfrage eines Freundes nach einer Lösung Diese Lösung öffentlich zugänglich machen! Generell: Wissen teilen Wo steht man? Open Source voranbringenDavid Decker · deckerweb.de · WP Camp 2012
  4. 4. Beispiel DECKERWEB Sehr viele Downloads & Nutzer - unerwartet! Viel positives Feedback, einige Kritik! 2 Kollaborationen (Dev4Press; Daniel Hüsken) Einige Forks... :) Feature bei WPMU.org Erwähnt in Session eines U.S. WordCamps Einige neue Übersetzungen (wächst) Generelle Anfragen (Spitzenreiter: Woo & Jigo...)David Decker · deckerweb.de · WP Camp 2012
  5. 5. ?Ziele Reizvolle Aufgabe? Lernen, weiterbilden, ausprobieren... Wissen teilen! Lösungen teilen! Reputation verbessern Der Öffentlichkeit stellen - Wo steht man? WordPress bzw. Open Source Contributor werden DEINE Gründe?David Decker · deckerweb.de · WP Camp 2012
  6. 6. !Lieber sein lassen, falls... ...man gar keine Zeit für Support hat ...nicht kritikfähig ...“SVN“ gar nicht geht :) ...es schon 500 Plugins der gleichenGeschmacksrichtung gibt... ...Geld verdienen wichtiger ist (dann: Marktplatzwechseln...!) WEITERE Gründe?David Decker · deckerweb.de · WP Camp 2012
  7. 7. Grundkonzept Eigentliche Funktionalität und Typ des Plugins Eigenständiges Plugin? Plugin-Plugin? Theme-Plugin? Functionality-/ Site-Plugin? (...MU-Plugin?) (Inline-) Dokumentation (ggf. gesondert für Entwickler) Lokalisierung! ...und Management! Bereit für Support? Evtl. Branding? / Evtl. „Vermarktung“? Bedingungen des Repositories bzw. Marktplatzes?David Decker · deckerweb.de · WP Camp 2012
  8. 8. Vorbereitung - Aufbau Hauptdatei mit Plugin-Kopf (Header, Meta, Lizenz) Funktionen? Klasse - Methoden? Variablen Konstanten Querschnittsaufgabe: Lokalisierung WordPress.org: readme.txt (generell sinnvoll!) Andere Repositories/ Marktplätze?David Decker · deckerweb.de · WP Camp 2012
  9. 9. (Datei-) Organisation Klare Ordnung aller Dateien/ Assets Saubere Benennung aller Dateien Alle benötigten Dateien/ Bibliotheken im Plugin! ../wp-content/plugins/ /wpcamp-test-plugin/ Textdomain? /css/ = Plugin-Slug! /images/ (wpcamp-test-plugin) /includes/ admin-settings.php Hauptdateiname? /js/ = Plugin-Slug! /languages/ (wpcamp-test-plugin.php) readme.txt wpcamp-test-plugin.phpDavid Decker · deckerweb.de · WP Camp 2012
  10. 10. Grundprinzipien I Alles mit Präfix bitte! //Funktionen: Bewährt: function ddw_bptb_init() { Initialen // inhalt Plugin-Name abgekürzt } o. Name der Agentur //Konstanten: abgekürzt... define( BPTB_PLUGIN_BASEDIR, ... ); Ziele: //Variablen: Einzigartig! $bptb_lang_dir Keine Kollisionen im //Klassen PHP-Namensraum class DDW_BuddyPress_Toolbar { // inhalt }David Decker · deckerweb.de · WP Camp 2012
  11. 11. Grundprinzipien II Code nur laden, wenn er gebraucht wird! is_admin(), is_multisite(), is_network_admin() usw. Code splitten (Optionen, eigentl. Formulare, etc.) CSS, Skripte einhängen/ „enqueue“ Backend/ Frontend beachten jQuery nur von WordPress verwenden NUR laden, wo es gebraucht wird, NICHT überall Abhängigkeiten beachten!Standardkonformer Code = performant und konfliktfreiDavid Decker · deckerweb.de · WP Camp 2012
  12. 12. Modulare Plugins „Extensible, or modular code, is code that can be modified, interacted with, added to, or manipulated . . . all without ever modifying the core code base.“ „Good extensible code makes it exceptionally easy to expand your own code base.“ --Pippin Williamson, pippinsplugins.com Nahtloses zusammenarbeiten mit WordPress sowieandere Plugins und Themes/ Frameworks Niemals den Core berühren! (WP, Plugins, Frameworks/ Themes) Hilf Dir selber ...und Deinen Benutzern!David Decker · deckerweb.de · WP Camp 2012
  13. 13. Modulare Plugins Know your hooks! Hooks und Filter == WordPress-Konzept! apply_filters() Einen Filter-Hook einrichten, der via add_filter() angesprochen wird add_filter() (Text-) Strings oder sonstige Daten über bestehenden "Hook" ÄNDERN has_filter() – Prüfen, ob ein Filter existiert do_action() Einen Einhängepunkt (Hook) einrichten, der alle eingehängten Funktionen via add_action() ausführt add_action() Eine Funktion in einen bestehenden Hook einhängen remove_action() Eine Funktion aus einem bestehenden Hook aushängen has_action() Erlaubt Prüfung, ob eine bestehende Aktion registriert wurdeDavid Decker · deckerweb.de · WP Camp 2012
  14. 14. Modulare Plugins WordPress Gravity Forms EDD Woo/ Jigo Erweiterbarer Code Genesis ... „Manipularer“ Code, d.h. filterbar Funktionen, CSS-Stile, JS-Skripte lassen sichaushängen, eigene einhängen (Übersetzungs-) Strings lassen sich einfach ändern(Filter!) Parameter aus Arrays lassen sich einfach anpassen,ergänzen (Filter!)David Decker · deckerweb.de · WP Camp 2012
  15. 15. Sicherheit ESCAPE-Funktionen (HTML, Attribute, URLs) SANITIZING-Funktionen - Benutzerein- undAusgaben absichern („heilen“) ! Der Codex hilft! Betrifft: codex.wordpress.org Admin-Optionen Alle (Admin-) Formulare, Eingaben, Ausgaben URLs! (bis hin zu WP-eigenen Permalinks etc.) Übersetzungs-Strings (Stichwort: Filter!)David Decker · deckerweb.de · WP Camp 2012
  16. 16. Coding Standards Danke, Gary Jones! (@GaryJ) Ohne „Regeln“ geht es auch hier nicht!Siehe: „Core Contributor Handbook“PHP:http://make.wordpress.org/core/handbook/coding-standards/#phpCSS:http://make.wordpress.org/core/handbook/coding-standards/css/David Decker · deckerweb.de · WP Camp 2012
  17. 17. Coding Standards Lesbar Verstehbar Erweiterbar Transportierbar TeamarbeitDavid Decker · deckerweb.de · WP Camp 2012
  18. 18. Best Practices Plugin: Modular arbeiten (Know your hooks :) Titel/ Slug bei WordPress.org checken! readme.txt Validator (Markdown-Format) Doku: alles beschreiben, was geht Doku: alle Hooks, Filter dokumentieren Doku: FAQ-Bereich? (vorsorglich...) Sprachdatei-Verzeichnis filterbar machen /wp-admin/ Plugin-Suche beachtenDavid Decker · deckerweb.de · WP Camp 2012
  19. 19. Wichtige Werkzeuge: define( WP_DEBUG, true ); (wp-config.php) Testen! Testen! Testen! Am besten auf einer live-Umgebung Multisite nicht vergessen! (Netzwerkweit aktivieren) WP-Version? PHP-Version? Serverumgebung? Plugins: Rewrite Rules Inspector Debug Bar Developer WP Admin Error Handler WordPress Beta Tester User Switching Codestyling Localization GlotPress (kein Plugin!)David Decker · deckerweb.de · WP Camp 2012
  20. 20. Plugin live, was nun? Downloads, Downloads, Downloads... Support, Support, Support! Updates, Updates, Updates... (Bugs, Bugs, Bugs...) Nach 3 Monaten? Nach 6 Monaten...? (Stichwort: Code Refactoring) Dokumentation live schalten & verbessern Evtl. eigenes Support-Forum (mehrsprachig?) Neue Ideen ;-)David Decker · deckerweb.de · WP Camp 2012
  21. 21. Würde ich es wieder tun? JA, auf jeden Fall! ;-) Unverzichtbare (Code-) Erkenntnisse und(menschliche) Erfahrungen! In einem Jahr mehr über WordPress gelernt, als in 5Jahren davor! Allerdings würde ich den Start besser vorbereiten... Und sonst? -- Die WordPress Community rockt! :)David Decker · deckerweb.de · WP Camp 2012
  22. 22. readme.txt Validator: http://wordpress.org/extend/plugins/about/validator/David Decker · deckerweb.de · WP Camp 2012
  23. 23. SVN - Subversion: http://wordpress.org/extend/plugins/about/svn/David Decker · deckerweb.de · WP Camp 2012
  24. 24. Verwendete Quellen: http://wordpress.org/extend/plugins/about/ (Dev Center) http://wordpress.org/extend/plugins/about/faq/ http://wordpress.org/extend/plugins/about/validator/ (redme.txt Check) http://pippinsplugins.com/lets-talk-extensible-code/ http://pippinsplugins.com/modular-plugins-presentation-from-wordcamp-kansas-city-2012/ http://make.wordpress.org/core/handbook/coding-standards/#php http://make.wordpress.org/core/handbook/coding-standards/css/ http://www.dev4press.com/2011/tutorials/wordpress/practical/how-to-optimize-plugin-loading/David Decker · deckerweb.de · WP Camp 2012
  25. 25. Danke! Fragen jetzt! Folien unter: deckerweb.de/wpcamp2012 plus: slideshare.net/deckerweb David Decker @deckerweb +David Decker deckerweb.de profiles.wordpress.org/daveshine translate.wpautobahn.comDavid Decker · deckerweb.de · WP Camp 2012
  26. 26. /** Call for break and add next session */add_action( wpcamp_berlin_2012, wpc_next_session_planning )function wpc_next_session_planning() { if ( is_break( array( 10min, coffee, wc ) ) ) { wpcamp_do_next_session(); echo __( Enjoy the break, wpcamp ); } else { wpcamp_do_celebrate_community(); echo __( Enjoy the conversation, wpcamp ); }}David Decker · deckerweb.de · WP Camp 2012

×