SlideShare a Scribd company logo
Building Themes from
Scratch with Frameworks
David Brattoli
Principal
Infinite Reality, LLC
Links
 https://developer.wordpress.org/themes/basics/template-hierarchy/
 https://codex.wordpress.org/Theme_Development#Template_Files
 http://underscores.me/
 http://components.underscores.me/
 http://foundation.zurb.com/
 http://jointswp.com/
• Create a New File in your favorite code editor
• Paste the following code:
jQuery(document).ready(function($) {
$(document).foundation();
});
• Save the file as “ foundation.js ” in your theme
folder
How To Build Your Responsive
Theme
Foundation Initialization File
How To Build Your Responsive
Theme
• Open Functions.php , located in your Underscores
theme, in your favorite code editor
• Look for a FunctionTitled: function themename_scripts
example: dabrattoli_theme_2016_scripts
• Click right above it and hit return a few times
• Then AddThis Code
function wcneo_foundation_scripts() {
}
• Then Save the file
How To Build Your Responsive Theme
• Find the stylesheet enqueues.
• Search for “Enqueue scripts and styles”
• Adding Foundation CSS : Add the following two lines to your function.
wp_enqueue_style( 'foundation-app',
get_stylesheet_directory_uri() . '/foundation/css/app.css' );
wp_enqueue_style( 'foundation-css',
get_stylesheet_directory_uri() .
'/foundation/css/foundation.css' );
wp_enqueue_style( 'foundation-icons',
get_template_directory_uri() .
'/foundation/foundation_icons/foundation-icons.css' );
Theme Functions.php
How To Build Your Responsive Theme
• Add a call for your custom styles to your function.
wp_enqueue_style( ‘demo-custom-style',
get_stylesheet_directory_uri() .
'/custom.css', array(), '1' );
• Add the calls for the foundation js files to your function.
wp_enqueue_script( 'foundation-js',
get_template_directory_uri() .
'/foundation/js/foundation.min.js', array(
'jquery' ), '1', true );
wp_enqueue_script( 'foundation-modernizr- js',
get_template_directory_uri() .
'/foundation/js/vendor/modernizr.js', array(
'jquery' ), '1', true );
Theme Functions.php
• Add a call for the foundation init, to your function.
wp_enqueue_script( 'foundation-init-js',
get_template_directory_uri() . '/foundation.js',
array( 'jquery' ), '1', true );
How To Build Your Responsive Theme
Theme Functions.php
Adding the Foundation Script and
Stylesheets to WordPress
function wcneo_foundation_scripts() {
wp_enqueue_style( 'foundation-app', get_stylesheet_directory_uri() .
'/foundation/css/app.css' );
wp_enqueue_style( 'foundation', get_stylesheet_directory_uri() .
'/foundation/css/foundation.css' );
wp_enqueue_style( ‘demo-custom-style',
get_stylesheet_directory_uri() . '/custom.css', array(), '1' );
wp_enqueue_script( 'foundation-js', get_template_directory_uri() .
'/foundation/js/foundation.min.js', array( 'jquery' ), '1', true );
wp_enqueue_script( 'foundation-modernizr- js',
get_template_directory_uri() . '/foundation/js/vendor/modernizr.js',
array( 'jquery' ), '1', true );
wp_enqueue_script( 'foundation-init-js', get_template_directory_uri() .
'/foundation.js', array( 'jquery' ), '1', true );
}
add_action( 'wp_enqueue_scripts', 'wcneo_foundation_scripts' );
Theme Functions.php
How To Build Your Responsive Theme
• You now have Foundation plugged into Underscores!
• Build your design out!
David Brattoli
Web:
www.Infiniterealityllc.com
www.Dabrattoli.com
Twitter: @DavidMBrattoli
Email: davidbrattoli@yahoo.com
david.brattoli@infiniterealityllc.com
Github:
https://github.com/dabrattoli
Contact Information

More Related Content

PPTX
WordPress Theme Development: Part 2
PPTX
WordPress theme development from scratch : ICT MeetUp 2013 Nepal
PDF
WordPress Theme Development for Designers
PPTX
Custom WordPress theme development
KEY
doing_it_right() with WordPress
PPTX
Rebrand WordPress Admin
PPTX
Creating Customizable Widgets for Unpredictable Needs
PDF
Word press templates
WordPress Theme Development: Part 2
WordPress theme development from scratch : ICT MeetUp 2013 Nepal
WordPress Theme Development for Designers
Custom WordPress theme development
doing_it_right() with WordPress
Rebrand WordPress Admin
Creating Customizable Widgets for Unpredictable Needs
Word press templates

What's hot (20)

PPT
WordPress Harrisburg Meetup - Best Practices
KEY
Extending Custom Post Types
PDF
Things I Wish I Had Known Before Developing a WordPress Theme
PDF
Intro to WordPress theme development
PDF
Becoming a better WordPress Developer
PDF
You Got React.js in My PHP
KEY
Custom Post Types in Depth at WordCamp Montreal
PPTX
Creating Dynamic Sidebars & Widgets in WordPress
PDF
Best Practices for WordPress
PDF
WordPress Theme Structure
PDF
Isomorphic WordPress Applications with NodeifyWP
PPTX
Best Practices for Building WordPress Applications
KEY
Introduction to Parse
PDF
WordPress as the Backbone(.js)
PPTX
Introduction to Parse backend for mobile developers
PDF
Modernizing WordPress Search with Elasticsearch
PPTX
Towards an Alternate WordPress Theme Structure
PDF
Transforming WordPress Search and Query Performance with Elasticsearch
PDF
WordCamp Raleigh 2015 - So You Want to Build and Release a Plugin
PDF
WordPress Theme Workshop: Part 1
WordPress Harrisburg Meetup - Best Practices
Extending Custom Post Types
Things I Wish I Had Known Before Developing a WordPress Theme
Intro to WordPress theme development
Becoming a better WordPress Developer
You Got React.js in My PHP
Custom Post Types in Depth at WordCamp Montreal
Creating Dynamic Sidebars & Widgets in WordPress
Best Practices for WordPress
WordPress Theme Structure
Isomorphic WordPress Applications with NodeifyWP
Best Practices for Building WordPress Applications
Introduction to Parse
WordPress as the Backbone(.js)
Introduction to Parse backend for mobile developers
Modernizing WordPress Search with Elasticsearch
Towards an Alternate WordPress Theme Structure
Transforming WordPress Search and Query Performance with Elasticsearch
WordCamp Raleigh 2015 - So You Want to Build and Release a Plugin
WordPress Theme Workshop: Part 1
Ad

Similar to Building themesfromscratchwithframeworks (20)

PPTX
Responsive themeworkshop wcneo2016
PDF
Best Wordprees development company in bangalore
PDF
Website development PDF which helps others make it easy
PPTX
Responsive Theme Workshop - WordCamp Columbus 2015
PPTX
The Way to Theme Enlightenment
PPTX
The Way to Theme Enlightenment 2017
PDF
WordPress Theming 101
PDF
WordPress Theme Workshop: Part 4
PPT
Easy Guide to WordPress Theme Integration
PDF
How to make a WordPress theme
KEY
WordPress Developers Israel Meetup #1
PPTX
Writing your own WordPress themes and plugins
PDF
Don't Fear the Custom Theme: How to build a custom WordPress theme with only ...
PPTX
Childthemes ottawa-word camp-1919
PPTX
WP Joburg Meetup 10: Genesis Framework by Trish Cornelius
PDF
Rapidly prototyping web applications using BackPress
PPTX
Building Potent WordPress Websites
PPTX
Theme development essentials columbus oh word camp 2012
PDF
Adopt or hack - how to hack a theme in a Drupal way
PPSX
Extending WordPress
Responsive themeworkshop wcneo2016
Best Wordprees development company in bangalore
Website development PDF which helps others make it easy
Responsive Theme Workshop - WordCamp Columbus 2015
The Way to Theme Enlightenment
The Way to Theme Enlightenment 2017
WordPress Theming 101
WordPress Theme Workshop: Part 4
Easy Guide to WordPress Theme Integration
How to make a WordPress theme
WordPress Developers Israel Meetup #1
Writing your own WordPress themes and plugins
Don't Fear the Custom Theme: How to build a custom WordPress theme with only ...
Childthemes ottawa-word camp-1919
WP Joburg Meetup 10: Genesis Framework by Trish Cornelius
Rapidly prototyping web applications using BackPress
Building Potent WordPress Websites
Theme development essentials columbus oh word camp 2012
Adopt or hack - how to hack a theme in a Drupal way
Extending WordPress
Ad

Recently uploaded (20)

PPTX
A Presentation on Artificial Intelligence
PPTX
Machine Learning_overview_presentation.pptx
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
Spectroscopy.pptx food analysis technology
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Machine learning based COVID-19 study performance prediction
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Cloud computing and distributed systems.
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
DOCX
The AUB Centre for AI in Media Proposal.docx
A Presentation on Artificial Intelligence
Machine Learning_overview_presentation.pptx
The Rise and Fall of 3GPP – Time for a Sabbatical?
“AI and Expert System Decision Support & Business Intelligence Systems”
Spectroscopy.pptx food analysis technology
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Unlocking AI with Model Context Protocol (MCP)
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Per capita expenditure prediction using model stacking based on satellite ima...
Machine learning based COVID-19 study performance prediction
Network Security Unit 5.pdf for BCA BBA.
Building Integrated photovoltaic BIPV_UPV.pdf
Cloud computing and distributed systems.
Advanced methodologies resolving dimensionality complications for autism neur...
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
The AUB Centre for AI in Media Proposal.docx

Building themesfromscratchwithframeworks

  • 1. Building Themes from Scratch with Frameworks David Brattoli Principal Infinite Reality, LLC
  • 2. Links  https://developer.wordpress.org/themes/basics/template-hierarchy/  https://codex.wordpress.org/Theme_Development#Template_Files  http://underscores.me/  http://components.underscores.me/  http://foundation.zurb.com/  http://jointswp.com/
  • 3. • Create a New File in your favorite code editor • Paste the following code: jQuery(document).ready(function($) { $(document).foundation(); }); • Save the file as “ foundation.js ” in your theme folder How To Build Your Responsive Theme Foundation Initialization File
  • 4. How To Build Your Responsive Theme • Open Functions.php , located in your Underscores theme, in your favorite code editor • Look for a FunctionTitled: function themename_scripts example: dabrattoli_theme_2016_scripts • Click right above it and hit return a few times • Then AddThis Code function wcneo_foundation_scripts() { } • Then Save the file
  • 5. How To Build Your Responsive Theme • Find the stylesheet enqueues. • Search for “Enqueue scripts and styles” • Adding Foundation CSS : Add the following two lines to your function. wp_enqueue_style( 'foundation-app', get_stylesheet_directory_uri() . '/foundation/css/app.css' ); wp_enqueue_style( 'foundation-css', get_stylesheet_directory_uri() . '/foundation/css/foundation.css' ); wp_enqueue_style( 'foundation-icons', get_template_directory_uri() . '/foundation/foundation_icons/foundation-icons.css' ); Theme Functions.php
  • 6. How To Build Your Responsive Theme • Add a call for your custom styles to your function. wp_enqueue_style( ‘demo-custom-style', get_stylesheet_directory_uri() . '/custom.css', array(), '1' ); • Add the calls for the foundation js files to your function. wp_enqueue_script( 'foundation-js', get_template_directory_uri() . '/foundation/js/foundation.min.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'foundation-modernizr- js', get_template_directory_uri() . '/foundation/js/vendor/modernizr.js', array( 'jquery' ), '1', true ); Theme Functions.php
  • 7. • Add a call for the foundation init, to your function. wp_enqueue_script( 'foundation-init-js', get_template_directory_uri() . '/foundation.js', array( 'jquery' ), '1', true ); How To Build Your Responsive Theme Theme Functions.php
  • 8. Adding the Foundation Script and Stylesheets to WordPress function wcneo_foundation_scripts() { wp_enqueue_style( 'foundation-app', get_stylesheet_directory_uri() . '/foundation/css/app.css' ); wp_enqueue_style( 'foundation', get_stylesheet_directory_uri() . '/foundation/css/foundation.css' ); wp_enqueue_style( ‘demo-custom-style', get_stylesheet_directory_uri() . '/custom.css', array(), '1' ); wp_enqueue_script( 'foundation-js', get_template_directory_uri() . '/foundation/js/foundation.min.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'foundation-modernizr- js', get_template_directory_uri() . '/foundation/js/vendor/modernizr.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'foundation-init-js', get_template_directory_uri() . '/foundation.js', array( 'jquery' ), '1', true ); } add_action( 'wp_enqueue_scripts', 'wcneo_foundation_scripts' ); Theme Functions.php
  • 9. How To Build Your Responsive Theme • You now have Foundation plugged into Underscores! • Build your design out!
  • 10. David Brattoli Web: www.Infiniterealityllc.com www.Dabrattoli.com Twitter: @DavidMBrattoli Email: davidbrattoli@yahoo.com david.brattoli@infiniterealityllc.com Github: https://github.com/dabrattoli Contact Information