SlideShare a Scribd company logo
1 of 30
BLUNT UMBRELLAS
WHO AM I 
• Gareth Hall (gareth@communica.co.nz) 
• Lead developer at Communica (communica.co.nz) 
• Consulting 
• Drupal, Laravel, Codeigniter, Symphony
SITE REQUIREMENTS 
• Responsive / Device Smart 
• Large Imagery 
• Immersive Experience 
• Modern Commerce Experience 
• Global Enforced Branding 
• Scalable and Adaptable 
• Multi Country 
• Multilingual 
• Multi Currency 
• Selectable Product Range 
• Country Specific Shipping 
Provider 
• Deadline 3 Weeks!
BIGGEST CHALLENGE 
HOW? 
• Multi Country 
• Multilingual 
• Multi Currency 
• Selectable Product Range 
• Country Specific Shipping Provider 
• Country Specific Stock
WE DIDN’T TRY 
• Used a multisite setup 
• Base Blunt Theme (Platform 
Level) 
• Base Blunt Module (Platform 
Level) 
• - 
• Each site is their own entity 
• Database 
• Files 
• Theme is required 
• Modules if required
. 
├── sites 
├── all 
│ ├── modules 
│ │ │── contrib 
│ │ └── custom 
│ │ └── blunt_module 
│ └── themes 
│ └── blunt_base_theme 
├── bluntumbrellas.com 
│ ├── files 
│ ├── local.settings.php 
│ ├── modules 
│ └── themes 
├── nz.bluntumbrellas.com 
│ ├── files 
│ ├── libraries 
│ ├── local.settings.php 
│ ├── modules 
│ │ └── blunt_nz (Child of blunt_base_theme) 
│ └── themes 
└── us.bluntumbrellas.com 
├── files 
├── libraries 
├── local.settings.php 
├── modules 
│ └── blunt_us 
└── themes 
└── blunt_us_theme (Child of blunt_base_theme)
OPEN PDF
/* 
* Implements hook_entity_view_mode_alter 
*/ 
function blunt_entity_view_mode_alter(&$view_mode, $context) { 
if ($context['entity_type'] == 'node' && $context['entity']->type == 'gallery') { 
$node = $context['entity']; 
switch ($node->field_gallery_type['und'][0]['value']) { 
case 'block_1': 
$view_mode = 'flexslider_thumbnail_nav'; 
break; 
case 'block_2': 
$view_mode = 'flexslider'; 
break; 
case 'block_3': 
$view_mode = 'flexslider_background'; 
break; 
} 
} 
}
DEMO
THEMING 
• Omega 4 
• Sass 
• Compass 
• Web Components (CSS)
VARIABLES 
• Variable should be named to describe it’s intent 
$text-grey: #5a5b5e; 
$text-color: $text-grey; 
$link-blue: #008fd7; 
$link-color: $link-blue;
FILE NAMES 
• Filename should describe it’s intent 
• _colors.scss 
• _dimensions.scss 
• _typography.scss
CSS WEB COMPONENTS 
• It’s encapsulated and reusable CSS components for your 
theme
HOW 
• Filename should match a class, id or element. 
• Try to use the SRP (single responsibility principal) 
• Meaning the file scope should be small and relevant to 
only the parent selector.
DEMO
PAY OFF 
• Ruby compiles pretty fast 
• Reduces bloat 
• Very readable 
• No disinformation
PICTURE AND 
BREAKPOINTS 
• Picture module will deliver alternate image sources based 
on device capabilities to prevent wasted bandwidth and 
optimise display for both screen and print.
; ======================================== 
; Breakpoints 
; ======================================== 
breakpoints[desktop] = (min-width: 1024px) 
breakpoints[tablet] = (min-width: 768px) and (max-width: 1024px) 
breakpoints[small_tablet] = (min-width: 414px) 
breakpoints[mobile] = (min-width: 320px) 
multipliers[desktop][] = 2x 
multipliers[tablet][] = 2x 
multipliers[small_tablet][] = 2x 
multipliers[mobile][] = 2x 
DEFINE YOUR 
BREAKPOINTS
SETUP 
• Create images styles 
• Create Mappings and Map
DEMO
GOTCHAS 
• Order breakpoints from large to small 
• Only works with field formatters 
• Tokens require some custom development
/** 
* Implements hook_token_info(). 
*/ 
function blunt_token_info() { 
return array( 
'tokens' => array( 
'term' => array( 
'technology_badge' => array( 
'name' => t('Picture: Technology Badge'), 
'description' => t('Picture group token for @field', array('@field' => 
'technology_badge')), 
), 
), 
), 
); 
} 
PICTURE & TOKENS
PICTURE & TOKENS 
/** 
* Implements hook_tokens(). 
*/ 
function blunt_tokens($type, $tokens, array $data = array(), array $options = array()) { 
if ($type == 'term' && !empty($data['term'])) { 
if (array_key_exists('technology_badge', $tokens)) { 
return blunt_get_replacement($tokens, $data, 'technology_badge'); 
} 
} 
return NULL; 
} 
/** 
* Get replacement values for our tokens. 
*/ 
function blunt_get_replacement($tokens, $data, $group) { 
$node = $data['term']; 
$item['item'] = $node->field_image['und'][0]; 
$mappings = (object) picture_mapping_load($group); 
$item['breakpoints'] = picture_get_mapping_breakpoints($mappings); 
$item['uri'] = $item['item']['uri']; 
$replacements[$tokens[$group]] = theme('picture', $item); 
return $replacements; 
}
HOVER STATE MENU 
• Use jQuery hover intent plugin
DRUPAL COMMERCE
SYMPHONY COMMERCE
MEMCACHE GOTCHA 
• Configure it correctly 
$conf['cache_backends'][] = 
'sites/all/modules/memcache/memcache.inc'; 
$conf['cache_class_cache_form'] = 'DrupalDatabaseCache'; 
$conf['cache_default_class'] = 'MemCacheDrupal'; 
$conf['memcache_key_prefix'] = ‘something_unique’;
QUESTIONS

More Related Content

Viewers also liked

Rapport final (draft croquis)
Rapport final (draft   croquis) Rapport final (draft   croquis)
Rapport final (draft croquis) Sandra Vespa
 
BI QUYET VE TUONG THACH CAO
BI QUYET VE TUONG THACH CAOBI QUYET VE TUONG THACH CAO
BI QUYET VE TUONG THACH CAOarchshop vn
 
Афиша культурных событий март 2014
Афиша культурных событий март 2014Афиша культурных событий март 2014
Афиша культурных событий март 2014Nazarovo_administration
 
Реестр муниципальных услуг
Реестр муниципальных услугРеестр муниципальных услуг
Реестр муниципальных услугNazarovo_administration
 
Langkah mudah memahami pembuatan dns server ubuntu 12.04
Langkah mudah memahami pembuatan dns server ubuntu 12.04Langkah mudah memahami pembuatan dns server ubuntu 12.04
Langkah mudah memahami pembuatan dns server ubuntu 12.04Riz Al-Atsary (Abu Uwais)
 
План культурных мероприятий на июнь 2014
План культурных мероприятий на июнь 2014План культурных мероприятий на июнь 2014
План культурных мероприятий на июнь 2014Nazarovo_administration
 
Афиша культурных событий. Февраль
Афиша культурных событий. ФевральАфиша культурных событий. Февраль
Афиша культурных событий. ФевральNazarovo_administration
 
Итоги работы административной комиссии
Итоги работы административной комиссииИтоги работы административной комиссии
Итоги работы административной комиссииNazarovo_administration
 
Протокол публичных слушаний "Западный"
Протокол публичных слушаний "Западный"Протокол публичных слушаний "Западный"
Протокол публичных слушаний "Западный"Nazarovo_administration
 
Перспективный план работы горсовета на 2014 год.
Перспективный план работы горсовета на 2014 год.Перспективный план работы горсовета на 2014 год.
Перспективный план работы горсовета на 2014 год.Nazarovo_administration
 
Organizational behavior modification (autosaved)2
Organizational behavior modification (autosaved)2Organizational behavior modification (autosaved)2
Organizational behavior modification (autosaved)2Pradeep Sah
 
BackupAgent presentation on Autotask integration
BackupAgent presentation on Autotask integrationBackupAgent presentation on Autotask integration
BackupAgent presentation on Autotask integrationBackupAgent
 

Viewers also liked (20)

LOS SENTIDOS
LOS SENTIDOSLOS SENTIDOS
LOS SENTIDOS
 
афиша октябрь
афиша октябрьафиша октябрь
афиша октябрь
 
Rapport final (draft croquis)
Rapport final (draft   croquis) Rapport final (draft   croquis)
Rapport final (draft croquis)
 
BI QUYET VE TUONG THACH CAO
BI QUYET VE TUONG THACH CAOBI QUYET VE TUONG THACH CAO
BI QUYET VE TUONG THACH CAO
 
Афиша культурных событий март 2014
Афиша культурных событий март 2014Афиша культурных событий март 2014
Афиша культурных событий март 2014
 
Culture
CultureCulture
Culture
 
Реестр муниципальных услуг
Реестр муниципальных услугРеестр муниципальных услуг
Реестр муниципальных услуг
 
Langkah mudah memahami pembuatan dns server ubuntu 12.04
Langkah mudah memahami pembuatan dns server ubuntu 12.04Langkah mudah memahami pembuatan dns server ubuntu 12.04
Langkah mudah memahami pembuatan dns server ubuntu 12.04
 
Techfa General Catalog
Techfa General CatalogTechfa General Catalog
Techfa General Catalog
 
План культурных мероприятий на июнь 2014
План культурных мероприятий на июнь 2014План культурных мероприятий на июнь 2014
План культурных мероприятий на июнь 2014
 
Афиша культурных событий. Февраль
Афиша культурных событий. ФевральАфиша культурных событий. Февраль
Афиша культурных событий. Февраль
 
Praktikum Pengenalan Dasar Database
Praktikum Pengenalan Dasar DatabasePraktikum Pengenalan Dasar Database
Praktikum Pengenalan Dasar Database
 
Капитальный ремонт
Капитальный ремонтКапитальный ремонт
Капитальный ремонт
 
Итоги работы административной комиссии
Итоги работы административной комиссииИтоги работы административной комиссии
Итоги работы административной комиссии
 
Poder para salvar
Poder para salvarPoder para salvar
Poder para salvar
 
Протокол публичных слушаний "Западный"
Протокол публичных слушаний "Западный"Протокол публичных слушаний "Западный"
Протокол публичных слушаний "Западный"
 
Перспективный план работы горсовета на 2014 год.
Перспективный план работы горсовета на 2014 год.Перспективный план работы горсовета на 2014 год.
Перспективный план работы горсовета на 2014 год.
 
Organizational behavior modification (autosaved)2
Organizational behavior modification (autosaved)2Organizational behavior modification (autosaved)2
Organizational behavior modification (autosaved)2
 
Final accounts
Final accountsFinal accounts
Final accounts
 
BackupAgent presentation on Autotask integration
BackupAgent presentation on Autotask integrationBackupAgent presentation on Autotask integration
BackupAgent presentation on Autotask integration
 

Similar to Blunt Umbrellas Website Showcase

Awesome html with ujs, jQuery and coffeescript
Awesome html with ujs, jQuery and coffeescriptAwesome html with ujs, jQuery and coffeescript
Awesome html with ujs, jQuery and coffeescriptAmir Barylko
 
Debugging in drupal 8
Debugging in drupal 8Debugging in drupal 8
Debugging in drupal 8Allie Jones
 
Php on the Web and Desktop
Php on the Web and DesktopPhp on the Web and Desktop
Php on the Web and DesktopElizabeth Smith
 
How and Where in GLORP
How and Where in GLORPHow and Where in GLORP
How and Where in GLORPESUG
 
Famo.us introduction
Famo.us introductionFamo.us introduction
Famo.us introductionAllen Wu
 
Going to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGoing to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGuillaume Laforge
 
Does my DIV look big in this?
Does my DIV look big in this?Does my DIV look big in this?
Does my DIV look big in this?glen_a_smith
 
Responsive Design for Data Visualization
Responsive Design for Data VisualizationResponsive Design for Data Visualization
Responsive Design for Data VisualizationMika Aldaba
 
Web development basics (Part-2)
Web development basics (Part-2)Web development basics (Part-2)
Web development basics (Part-2)Rajat Pratap Singh
 
Responsive WordPress workflow
Responsive WordPress workflowResponsive WordPress workflow
Responsive WordPress workflowJames Bundey
 
CapitalCamp Features
CapitalCamp FeaturesCapitalCamp Features
CapitalCamp FeaturesPhase2
 
#NewMeetup Performance
#NewMeetup Performance#NewMeetup Performance
#NewMeetup PerformanceJustin Cataldo
 
Everything is Awesome - Cutting the Corners off the Web
Everything is Awesome - Cutting the Corners off the WebEverything is Awesome - Cutting the Corners off the Web
Everything is Awesome - Cutting the Corners off the WebJames Rakich
 
Building and Maintaining a Distribution in Drupal 7 with Features
Building and Maintaining a  Distribution in Drupal 7 with FeaturesBuilding and Maintaining a  Distribution in Drupal 7 with Features
Building and Maintaining a Distribution in Drupal 7 with FeaturesNuvole
 

Similar to Blunt Umbrellas Website Showcase (20)

Awesome html with ujs, jQuery and coffeescript
Awesome html with ujs, jQuery and coffeescriptAwesome html with ujs, jQuery and coffeescript
Awesome html with ujs, jQuery and coffeescript
 
Debugging in drupal 8
Debugging in drupal 8Debugging in drupal 8
Debugging in drupal 8
 
Php on the Web and Desktop
Php on the Web and DesktopPhp on the Web and Desktop
Php on the Web and Desktop
 
How and Where in GLORP
How and Where in GLORPHow and Where in GLORP
How and Where in GLORP
 
Famo.us introduction
Famo.us introductionFamo.us introduction
Famo.us introduction
 
Intro to HTML5
Intro to HTML5Intro to HTML5
Intro to HTML5
 
Going to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGoing to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific Languages
 
Does my DIV look big in this?
Does my DIV look big in this?Does my DIV look big in this?
Does my DIV look big in this?
 
Html5 more than just html5 v final
Html5  more than just html5 v finalHtml5  more than just html5 v final
Html5 more than just html5 v final
 
Responsive Design for Data Visualization
Responsive Design for Data VisualizationResponsive Design for Data Visualization
Responsive Design for Data Visualization
 
Web development basics (Part-2)
Web development basics (Part-2)Web development basics (Part-2)
Web development basics (Part-2)
 
Jquery fundamentals
Jquery fundamentalsJquery fundamentals
Jquery fundamentals
 
Responsive WordPress workflow
Responsive WordPress workflowResponsive WordPress workflow
Responsive WordPress workflow
 
CapitalCamp Features
CapitalCamp FeaturesCapitalCamp Features
CapitalCamp Features
 
#NewMeetup Performance
#NewMeetup Performance#NewMeetup Performance
#NewMeetup Performance
 
Soc research
Soc researchSoc research
Soc research
 
Design Patterns
Design PatternsDesign Patterns
Design Patterns
 
Everything is Awesome - Cutting the Corners off the Web
Everything is Awesome - Cutting the Corners off the WebEverything is Awesome - Cutting the Corners off the Web
Everything is Awesome - Cutting the Corners off the Web
 
Building and Maintaining a Distribution in Drupal 7 with Features
Building and Maintaining a  Distribution in Drupal 7 with FeaturesBuilding and Maintaining a  Distribution in Drupal 7 with Features
Building and Maintaining a Distribution in Drupal 7 with Features
 
Javascript Design Patterns
Javascript Design PatternsJavascript Design Patterns
Javascript Design Patterns
 

Recently uploaded

Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalLionel Briand
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsSafe Software
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Cizo Technology Services
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceBrainSell Technologies
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 
Odoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 EnterpriseOdoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 Enterprisepreethippts
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesPhilip Schwarz
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odishasmiwainfosol
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Angel Borroy López
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptrcbcrtm
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesŁukasz Chruściel
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfMarharyta Nedzelska
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Andreas Granig
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 

Recently uploaded (20)

Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive Goal
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort ServiceHot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data Streams
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. Salesforce
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 
Odoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 EnterpriseOdoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 Enterprise
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a series
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.ppt
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New Features
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdf
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 

Blunt Umbrellas Website Showcase

  • 2. WHO AM I • Gareth Hall (gareth@communica.co.nz) • Lead developer at Communica (communica.co.nz) • Consulting • Drupal, Laravel, Codeigniter, Symphony
  • 3. SITE REQUIREMENTS • Responsive / Device Smart • Large Imagery • Immersive Experience • Modern Commerce Experience • Global Enforced Branding • Scalable and Adaptable • Multi Country • Multilingual • Multi Currency • Selectable Product Range • Country Specific Shipping Provider • Deadline 3 Weeks!
  • 4. BIGGEST CHALLENGE HOW? • Multi Country • Multilingual • Multi Currency • Selectable Product Range • Country Specific Shipping Provider • Country Specific Stock
  • 5. WE DIDN’T TRY • Used a multisite setup • Base Blunt Theme (Platform Level) • Base Blunt Module (Platform Level) • - • Each site is their own entity • Database • Files • Theme is required • Modules if required
  • 6. . ├── sites ├── all │ ├── modules │ │ │── contrib │ │ └── custom │ │ └── blunt_module │ └── themes │ └── blunt_base_theme ├── bluntumbrellas.com │ ├── files │ ├── local.settings.php │ ├── modules │ └── themes ├── nz.bluntumbrellas.com │ ├── files │ ├── libraries │ ├── local.settings.php │ ├── modules │ │ └── blunt_nz (Child of blunt_base_theme) │ └── themes └── us.bluntumbrellas.com ├── files ├── libraries ├── local.settings.php ├── modules │ └── blunt_us └── themes └── blunt_us_theme (Child of blunt_base_theme)
  • 8.
  • 9.
  • 10. /* * Implements hook_entity_view_mode_alter */ function blunt_entity_view_mode_alter(&$view_mode, $context) { if ($context['entity_type'] == 'node' && $context['entity']->type == 'gallery') { $node = $context['entity']; switch ($node->field_gallery_type['und'][0]['value']) { case 'block_1': $view_mode = 'flexslider_thumbnail_nav'; break; case 'block_2': $view_mode = 'flexslider'; break; case 'block_3': $view_mode = 'flexslider_background'; break; } } }
  • 11. DEMO
  • 12. THEMING • Omega 4 • Sass • Compass • Web Components (CSS)
  • 13. VARIABLES • Variable should be named to describe it’s intent $text-grey: #5a5b5e; $text-color: $text-grey; $link-blue: #008fd7; $link-color: $link-blue;
  • 14. FILE NAMES • Filename should describe it’s intent • _colors.scss • _dimensions.scss • _typography.scss
  • 15. CSS WEB COMPONENTS • It’s encapsulated and reusable CSS components for your theme
  • 16. HOW • Filename should match a class, id or element. • Try to use the SRP (single responsibility principal) • Meaning the file scope should be small and relevant to only the parent selector.
  • 17. DEMO
  • 18. PAY OFF • Ruby compiles pretty fast • Reduces bloat • Very readable • No disinformation
  • 19. PICTURE AND BREAKPOINTS • Picture module will deliver alternate image sources based on device capabilities to prevent wasted bandwidth and optimise display for both screen and print.
  • 20. ; ======================================== ; Breakpoints ; ======================================== breakpoints[desktop] = (min-width: 1024px) breakpoints[tablet] = (min-width: 768px) and (max-width: 1024px) breakpoints[small_tablet] = (min-width: 414px) breakpoints[mobile] = (min-width: 320px) multipliers[desktop][] = 2x multipliers[tablet][] = 2x multipliers[small_tablet][] = 2x multipliers[mobile][] = 2x DEFINE YOUR BREAKPOINTS
  • 21. SETUP • Create images styles • Create Mappings and Map
  • 22. DEMO
  • 23. GOTCHAS • Order breakpoints from large to small • Only works with field formatters • Tokens require some custom development
  • 24. /** * Implements hook_token_info(). */ function blunt_token_info() { return array( 'tokens' => array( 'term' => array( 'technology_badge' => array( 'name' => t('Picture: Technology Badge'), 'description' => t('Picture group token for @field', array('@field' => 'technology_badge')), ), ), ), ); } PICTURE & TOKENS
  • 25. PICTURE & TOKENS /** * Implements hook_tokens(). */ function blunt_tokens($type, $tokens, array $data = array(), array $options = array()) { if ($type == 'term' && !empty($data['term'])) { if (array_key_exists('technology_badge', $tokens)) { return blunt_get_replacement($tokens, $data, 'technology_badge'); } } return NULL; } /** * Get replacement values for our tokens. */ function blunt_get_replacement($tokens, $data, $group) { $node = $data['term']; $item['item'] = $node->field_image['und'][0]; $mappings = (object) picture_mapping_load($group); $item['breakpoints'] = picture_get_mapping_breakpoints($mappings); $item['uri'] = $item['item']['uri']; $replacements[$tokens[$group]] = theme('picture', $item); return $replacements; }
  • 26. HOVER STATE MENU • Use jQuery hover intent plugin
  • 29. MEMCACHE GOTCHA • Configure it correctly $conf['cache_backends'][] = 'sites/all/modules/memcache/memcache.inc'; $conf['cache_class_cache_form'] = 'DrupalDatabaseCache'; $conf['cache_default_class'] = 'MemCacheDrupal'; $conf['memcache_key_prefix'] = ‘something_unique’;