SlideShare a Scribd company logo
WordPress Theme
Workshop: Customizer
November 4th, 2017
David Bisset
davidbisset.com / @dimensionmedia
Theme Customization API
function bwpy_customizer( $wp_customize ) {
// customizer build code
}
add_action( 'customize_register', 'bwpy_customizer' );
The WordPress Theme Customization API is a way to build
customization options directly into your theme or plugin
without having to build custom options through the Settings API.
Theme Customization API
$wp_customize->add_section( 'bwpy_content_options_section' , array(
'title' => __( 'Content Options', 'bwpy' ),
'priority' => 200,
) );
Part 1 – Customizer Section
Theme Customization API
$wp_customize->add_setting( 'bwpy_page_comment_toggle', array(
'default' => 1
) );
Part 2 – Customizer Setting
Customizer settings are what really let you hack into WordPress
with minimal effort. Creating theme options is not just about
HTML forms.
The information passed through those forms need to save, be
accessible, etc.That’s what customizer settings do for you.
Theme Customization API
$wp_customize->add_control( 'bwpy_page_comment_toggle', array(
'label' => __( 'Show comments on pages?', 'bwpy' ),
'section' => 'bwpy_content_options_section',
'type' => 'checkbox',
'priority' => 10
) );
Part 3 – Customizer Control
This is the final step in creating an option and where things get
the most detailed. Here you determine what kind of option to
create, what its label will be, and what section it will fall under,
among other things.

More Related Content

PDF
Shortcodes: WordUp Pompey! Feb-2012
PPT
Easy Guide to WordPress Theme Integration
KEY
Plugin Options
PDF
Theme Wrangling 101
TXT
Seo hints
PPTX
WordPress 3: Leveraging the Shiny New Features
PPT
WordPress Child Themes
PDF
WordPress Theme Workshop: Theme Setup
Shortcodes: WordUp Pompey! Feb-2012
Easy Guide to WordPress Theme Integration
Plugin Options
Theme Wrangling 101
Seo hints
WordPress 3: Leveraging the Shiny New Features
WordPress Child Themes
WordPress Theme Workshop: Theme Setup

Similar to WordPress Theme Workshop: Customizer (19)

PDF
Creating Customizer Options for Themes and Plugins
PDF
Using The WordPress Customizer
PDF
WordPress customizer: for themes and more
PDF
Developing for the WordPress Customizer
PDF
Developing For The WordPress Customizer
PPTX
WordPress customizer for themes and more
PDF
WordCamp Praga 2015
PDF
Customize it.
PDF
Build WordPress themes like a heavyweight - WordCamp Lancaster 2013
PDF
Customizer-ing Theme Options: A Visual Playground
PPTX
WordPress theme setting page
PDF
Image manipulation in WordPress 3.5
PDF
Theme Customization
PDF
WordCamp Bristol 2019 - WordPress custom theme building
PPTX
Customizing WordPress Themes
PPTX
Building your first plugin
PPTX
Think Before You Submit Themes on WordPress dot Org
PDF
Bending word press to your will
PPTX
Customizing the WordPress Customizer
Creating Customizer Options for Themes and Plugins
Using The WordPress Customizer
WordPress customizer: for themes and more
Developing for the WordPress Customizer
Developing For The WordPress Customizer
WordPress customizer for themes and more
WordCamp Praga 2015
Customize it.
Build WordPress themes like a heavyweight - WordCamp Lancaster 2013
Customizer-ing Theme Options: A Visual Playground
WordPress theme setting page
Image manipulation in WordPress 3.5
Theme Customization
WordCamp Bristol 2019 - WordPress custom theme building
Customizing WordPress Themes
Building your first plugin
Think Before You Submit Themes on WordPress dot Org
Bending word press to your will
Customizing the WordPress Customizer
Ad

More from David Bisset (20)

PDF
WordPress Theme Workshop: Part 0
PDF
WordPress Theme Workshop: Part 1
PDF
WordPress Theme Workshop: Part 2
PDF
WordPress Theme Workshop: Part 3
PDF
WordPress Theme Workshop: Part 4
PDF
WordPress Theme Workshop: CSS/JS
PDF
WordPress Theme Workshop: Internationalization
PDF
WordPress Theme Workshop: Misc
PDF
WordPress Theme Workshop: Widgets
PDF
WordPress Theme Workshop: Menus
PDF
WordPress Theme Workshop: Sidebars
PPTX
BuddyPress & Higher Education
PDF
WordPress Meetup (Davie, FL) - Top 9 April 2016
PDF
WordCamp Tampa 2015
PDF
BuddyPress v4
PDF
WPSessions - Thinking Outside The Box With BuddyPress
PDF
SunShine PHP
PDF
Building Next Generation Applications With BuddyPress
PDF
Be a Part of Something Bigger: Get Involved with WordPress
PDF
WordPress Meetup - Top 9 September 2015
WordPress Theme Workshop: Part 0
WordPress Theme Workshop: Part 1
WordPress Theme Workshop: Part 2
WordPress Theme Workshop: Part 3
WordPress Theme Workshop: Part 4
WordPress Theme Workshop: CSS/JS
WordPress Theme Workshop: Internationalization
WordPress Theme Workshop: Misc
WordPress Theme Workshop: Widgets
WordPress Theme Workshop: Menus
WordPress Theme Workshop: Sidebars
BuddyPress & Higher Education
WordPress Meetup (Davie, FL) - Top 9 April 2016
WordCamp Tampa 2015
BuddyPress v4
WPSessions - Thinking Outside The Box With BuddyPress
SunShine PHP
Building Next Generation Applications With BuddyPress
Be a Part of Something Bigger: Get Involved with WordPress
WordPress Meetup - Top 9 September 2015
Ad

Recently uploaded (20)

PPTX
Big Data Technologies - Introduction.pptx
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
PDF
Modernizing your data center with Dell and AMD
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Electronic commerce courselecture one. Pdf
PDF
NewMind AI Monthly Chronicles - July 2025
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Empathic Computing: Creating Shared Understanding
PPTX
Cloud computing and distributed systems.
PDF
KodekX | Application Modernization Development
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PPTX
A Presentation on Artificial Intelligence
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
Big Data Technologies - Introduction.pptx
“AI and Expert System Decision Support & Business Intelligence Systems”
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
Modernizing your data center with Dell and AMD
Diabetes mellitus diagnosis method based random forest with bat algorithm
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Electronic commerce courselecture one. Pdf
NewMind AI Monthly Chronicles - July 2025
Spectral efficient network and resource selection model in 5G networks
Empathic Computing: Creating Shared Understanding
Cloud computing and distributed systems.
KodekX | Application Modernization Development
CIFDAQ's Market Insight: SEC Turns Pro Crypto
A Presentation on Artificial Intelligence
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Encapsulation_ Review paper, used for researhc scholars
Reach Out and Touch Someone: Haptics and Empathic Computing

WordPress Theme Workshop: Customizer

  • 1. WordPress Theme Workshop: Customizer November 4th, 2017 David Bisset davidbisset.com / @dimensionmedia
  • 2. Theme Customization API function bwpy_customizer( $wp_customize ) { // customizer build code } add_action( 'customize_register', 'bwpy_customizer' ); The WordPress Theme Customization API is a way to build customization options directly into your theme or plugin without having to build custom options through the Settings API.
  • 3. Theme Customization API $wp_customize->add_section( 'bwpy_content_options_section' , array( 'title' => __( 'Content Options', 'bwpy' ), 'priority' => 200, ) ); Part 1 – Customizer Section
  • 4. Theme Customization API $wp_customize->add_setting( 'bwpy_page_comment_toggle', array( 'default' => 1 ) ); Part 2 – Customizer Setting Customizer settings are what really let you hack into WordPress with minimal effort. Creating theme options is not just about HTML forms. The information passed through those forms need to save, be accessible, etc.That’s what customizer settings do for you.
  • 5. Theme Customization API $wp_customize->add_control( 'bwpy_page_comment_toggle', array( 'label' => __( 'Show comments on pages?', 'bwpy' ), 'section' => 'bwpy_content_options_section', 'type' => 'checkbox', 'priority' => 10 ) ); Part 3 – Customizer Control This is the final step in creating an option and where things get the most detailed. Here you determine what kind of option to create, what its label will be, and what section it will fall under, among other things.