May the core be with you - JandBeyond 2014
-
Upload
chad-windnagle -
Category
Presentations & Public Speaking
-
view
106 -
download
1
description
Transcript of May the core be with you - JandBeyond 2014
![Page 1: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/1.jpg)
May The Core Be With You
![Page 2: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/2.jpg)
About this talk
![Page 3: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/3.jpg)
![Page 4: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/4.jpg)
![Page 5: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/5.jpg)
Why Use More Core?
![Page 6: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/6.jpg)
Easier Upgrades
![Page 7: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/7.jpg)
Extension Compatibility
![Page 8: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/8.jpg)
![Page 9: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/9.jpg)
Knowledge Transfer
![Page 10: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/10.jpg)
Future Proof
![Page 11: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/11.jpg)
![Page 12: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/12.jpg)
![Page 13: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/13.jpg)
How To:Make The Most Out of Core
![Page 14: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/14.jpg)
Example 1:Carousel With Modules
![Page 15: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/15.jpg)
Order of Operations1. Add chrome to modules.php2. Add position to template index.php3. Add new custom module layout4. Add module instances to position5. Check the result
![Page 16: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/16.jpg)
function modChrome_carouselInner($module, &$params, $attribs){
$img = $params->get('backgroundimage');$sfx = htmlspecialchars($params-
>get('moduleclass_sfx'));
if ($module->content) {echo "<div class=\"item" . $sfx . "\">";echo "<img src=\"" . $img . "\" \>";echo "<div class=\"carousel-caption\">";echo $module->content;echo "</div>";echo "</div>";
}}
modules.php
![Page 17: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/17.jpg)
<?php if ($this->countModules('carousel')): ?><div id="bootstrap-carousel" class="carousel slide">
<div class="carousel-inner"><jdoc:include type="modules"
name="carousel" style="carouselInner"
/></div><a class="carousel-control left"
href="#bootstrap-carousel" data-slide="prev">‹
</a><a class="carousel-control right"
href="#bootstrap-carousel" data-slide="next">›
</a></div>
<?php endif; ?>
template’s index.php
![Page 18: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/18.jpg)
<?php echo $module->content; ?>
mod_custom new layout
![Page 19: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/19.jpg)
Sanity CheckFile Locations
Template Index File (new module positon):<jroot>/templates/my_template/index.php
Modules.php File (new module chrome):<jroot>/templates/my_template/html/modules.php
Custom Module Layout (for mod_custom):<jroot>/templates/my_template/html/mod_custom/text.php
![Page 20: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/20.jpg)
![Page 21: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/21.jpg)
Position: carouselContent: description textDiv Class: active (first slide/module)Title: slide title
![Page 22: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/22.jpg)
Background Image: Slide Image
![Page 23: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/23.jpg)
Select new alternate layout
![Page 24: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/24.jpg)
Results
![Page 25: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/25.jpg)
![Page 26: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/26.jpg)
![Page 27: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/27.jpg)
Example 2:Alternate Category Layout
![Page 28: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/28.jpg)
Order of Operations1. Copy some view files to the template2. Make some minor code changes
a. this is an ‘alternate layout’3. Add new menu item4. Check the result
![Page 29: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/29.jpg)
Copy view files to template
![Page 30: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/30.jpg)
<?xml version="1.0" encoding="utf-8"?><metadata>
<layout title="COM_CONTENT_CATEGORY_VIEW_BLOG_TITLE" option="COM_CONTENT_CATEGORY_VIEW_BLOG_OPTION">
<helpkey =
"JHELP_MENUS_MENU_ITEM_ARTICLE_CATEGORY_BLOG"/><message>
<![CDATA[COM_CONTENT_CATEGORY_VIEW_BLOG_DESC]]>
</message></layout>
blog.xml
![Page 31: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/31.jpg)
<?xml version="1.0" encoding="utf-8"?><metadata>
<layout title="COM_CONTENT_CATEGORY_VIEW_ACCORDION_TITLE" option="COM_CONTENT_CATEGORY_VIEW_ACCORDION_OPTION">
<helpkey =
"JHELP_MENUS_MENU_ITEM_ARTICLE_CATEGORY_BLOG"/><message>
<![CDATA[COM_CONTENT_CATEGORY_VIEW_BLOG_DESC]]>
</message></layout>
accordion.xml
![Page 32: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/32.jpg)
<div class="accordion-group"><div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#cat-accord-<?php echo
$this->item->catid; ?>" href="#accordion-<?php echo $this-
>item->id; ?>"><?php echo $this->item->title; ?
></a>
</div> <div id="accordion-<?php echo $this->item->id; ?>" class="accordion-body collapse"> <?php // the content ?> </div></div>
accordion_item.php
![Page 33: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/33.jpg)
![Page 34: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/34.jpg)
![Page 35: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/35.jpg)
![Page 36: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/36.jpg)
Let’s just recap
![Page 37: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/37.jpg)
![Page 38: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/38.jpg)
500+ Extensions!?(Or we could just use core…)
![Page 39: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/39.jpg)
Example 3:Language Manager ‘Hack’
![Page 40: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/40.jpg)
![Page 41: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/41.jpg)
![Page 42: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/42.jpg)
<?php // some view, or model, or controller, or anything ?>
<?php echo JText::_('GLOBAL_CONSTANT'); ?>
<?php // the rest of your code ?>
Any Code in Joomla!
![Page 43: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/43.jpg)
What’s next?
![Page 44: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/44.jpg)
![Page 45: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/45.jpg)
Bloated CMS
![Page 46: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/46.jpg)
![Page 47: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/47.jpg)
Improve the CMS
![Page 48: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/48.jpg)
Be Creative
![Page 49: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/49.jpg)
Thanks!
![Page 50: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/50.jpg)
![Page 51: May the core be with you - JandBeyond 2014](https://reader036.fdocuments.net/reader036/viewer/2022062617/54c72f954a7959e7698b45c9/html5/thumbnails/51.jpg)
“Fear is the path to the Dark Side. Fear leads to anger, anger leads to hate, hate leads to suffering.”- Yoda
Better Understood as:
“Extensions are the path to the dark side. Extensions lead to migration problems, swearing and suffering.”- Unknown