SlideShare a Scribd company logo
1 of 34
Download to read offline
Andreas Zahner, Alkacon Software
Workshop Track
Bootstrap your templates
with OpenCms 9
09.10.2013
● The OpenCms 9 Bootstrap template
● Module structure
● Content containers
● Available content types
● Cloning OpenCms modules
● How to clone a module
● Customizing the cloned module
● Using another Bootstrap theme
● Modifying the formatter HTML output
● Creating pages using the customized formatters
● Add a new content type
2
Agenda
● Module Structure of previous OpenCms
versions:
● One Template module
● For each resource type, an extra module has been
developed including the type definition, XSDs,
localization and formatters
● OpenCms 9 Bootstrap template:
● Only 2 modules contain the template and all
necessary functionality for the website
● Reason: cloning the modules using the integrated
functions is easier and faster
3
Bootstrap template - Structure
● Schemas module
(com.alkacon.bootstrap.schemas)
● This module contains everything for the
definition of the available content elements
● Resource type definitions
● XSD files
● Localization bundles
4
Bootstrap template - Structure
● Formatters module
(com.alkacon.bootstrap.formatters)
● This module contains all components that are
used for the website frontend output
● Main template
● Template resources
● JSP elements for the template (e.g. navigation)
● Dynamic functions (e.g. Login box)
● Formatters for all types of schema module
5
Bootstrap template - Structure
● The bootstrap template has 5 content
containers
● Top container
● For full width content
● Middle left container, middle right container
● The column ratio can be adjusted using a property
Example: 9 – 3: left column uses 9 grid units, the right
column uses 3 grid units (the default setting)
● Bottom container
● For full width content
● Foot container
● Only used for sticky footers (i.e. flexible content)
6
Bootstrap template - Containers
7
Bootstrap template - Containers
● Screenshot of container structure
● Currently available content types:
● Flexible Content
● Image Row
● Hero / Jumbotron
● News Article
● Product
● Slider
● Tabs / Accordion
● Text Block
8
Bootstrap template - Types
● Advantages of cloning the shipped modules
● Fast and easy project start (no need to start with
"Adam & Eve")
● Use existing content types with different HTML
output
● Modify the page template by using
● A different container structure (optional)
● A different Bootstrap theme (optional)
● Clone existing content types and modify their fields
according to your requirements
9
Cloning OpenCms modules
● Use the dynamic function "Clone a module"
that is part of the demo formatter module for
clone operations
10
Cloning OpenCms modules
● The function form uses the Java bean
"CmsCloneModule" of the OpenCms core
package
"org.opencms.workplace.tools.modules"
● getter and setter methods for all configurable
options
● executeModuleClone() starts the clone process
● The module is copied first
● Internal references are adjusted in the copied module
● The module is added to the OpenCms module
configuration
● Optionally, the site contents references can be adjusted
to use the new module clone
11
Cloning OpenCms modules
● Clone the formatter module (1)
● Select the source formatters module from the drop
down list
● Be sure to uncheck the delete option if you want to
keep the old module in the system
● Enter the new module and author information
● Be sure that the package name of the module does not
exist yet
● For our examples, we create a clone named
"com.mycompany.formatters"
12
Cloning OpenCms modules
● Clone the formatter module (2)
● Translation options are only important when
cloning a module containing resource type
definitions
● Source and target prefix names: If the resource
types of the module have a prefix (like "bs"), this
will be replaced by the target prefix name
● The Formatters source module has to be entered
to ensure that the XSD files reference the correct
formatter JSPs after cloning all required modules
● Uncheck the option to replace schema locations
and resource types when cloning the formatters
module (i.e. without resource types)
13
Cloning OpenCms modules
● After cloning, the new module is shown in the
Module Management view
● The resources of the cloned module can be
checked below the /system/modules/ folder of
the root site
● If a module with resource type definitions was
cloned, the servlet container has to be
restarted
14
Cloning OpenCms modules
● Live Demo
15
Live Demo
Demo
Demo Demo
Demo
デモ
● Switching to another ready to use Bootstrap
theme
● All theme specific files (CSS, JavaScript, images)
are placed inside the resources/ folder of the
formatter module
● Delete all these files and replace them with the
necessary files of the theme you want to use
16
Customizing the cloned module
● Switching to another ready to use Bootstrap
theme
● Edit the template JSP to use the correct CSS and
JS files of the theme
● Adjust the HTML output of the template JSP
according to the requirements of the new theme (if
required)
17
Customizing the cloned module
...
<head>
...
<cms:headincludes type="css" closetags="true"
defaults="%(link.weak:/system/modules/com.mycompany.formatters/resources/css/bootstrap.min.c
ss)
|%(link.weak:/system/modules/com.mycompany.formatters/resources/css/bootstrap-
responsive.min.css)
|%(link.weak:/system/modules/com.mycompany.formatters/resources/css/bootstrap-
overrides.css)
...
|%(link.weak:/system/modules/com.mycompany.formatters/resources/css/page.css)" />
...
<cms:headincludes type="javascript" defaults="http://code.jquery.com/jquery-latest.js
|%(link.weak:/system/modules/com.mycompany.formatters/resources/js/bootstrap.min.js)
|%(link.weak:/system/modules/com.mycompany.formatters/resources/js/theme.js)" />
...
</head><body>
...
18
Customizing the cloned module
● Change the HTML output of the template
element JSPs (e.g. main navigation) for the
new theme
19
Customizing the cloned module
<div class="navbar">
<div class="navbar-inner">
<a class="btn btn-navbar" data-
toggle="collapse" data-target=".nav-
collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a><!-- /nav-collapse -->
<div class="nav-collapse collapse">
<ul class="nav top-2">
...
<div class="navbar navbar-inverse navbar-
static-top">
<div class="navbar-inner"><div
class="container">
<a class="btn btn-navbar" data-
toggle="collapse" data-target=".nav-
collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a><!-- /nav-collapse -->
<a class="brand"
href="index.html"><strong>My
Company</strong></a>
<div class="nav-collapse collapse">
<ul class="nav pull-right">
● Change the HTML output of the formatter JSPs
(e.g. text block) for the new theme
20
Customizing the cloned module
...
<cms:formatter var="content">
...
<c:if
test="${paragraph.value.Headline.isSet}">
<div
class="headline"><h3>${paragraph.rdfa.Hea
dline}>${paragraph.value.Headline}</h3></
div>
</c:if>
...
<c:if
test="${paragraph.value.Link.exists}">
<p><a class="btn-u btn-u-small"
href="<cms:link>${paragraph.value.Link.va
lue.URI}</cms:link>">${paragraph.value.Li
nk.value.Text}</a></p>
</c:if>
...
...
<cms:formatter var="content">
...
<c:if
test="${paragraph.value.Headline.isSet}">
<div
class="section_header"><h3>${paragraph.rd
fa.Headline}>${paragraph.value.Headline}<
/h3></div>
</c:if>
...
<c:if
test="${paragraph.value.Link.exists}">
<p><a class="btn btn-small"
href="<cms:link>${paragraph.value.Link.va
lue.URI}</cms:link>">${paragraph.value.Li
nk.value.Text}</a></p>
</c:if>
...
● Create a subsite that uses your cloned
template and formatters
● Set the "template" property value on the subsite
folder to your template JSP, e.g.
"/system/modules/com.mycompany.formatters/tem
plates/bootstrap-page.jsp"
21
Customizing the cloned module
● Edit the subsite configuration to make the
content types use the correct formatter JSPs if
only the formatter module was cloned
22
Customizing the cloned module
● After these steps, you can start creating your
pages with the cloned template and formatters
23
Customizing the cloned module
● Live Demo
24
Live Demo
Demo
Demo Demo
Demo
デモ
● Add a new content type that you need for your
website
● Example: Feature content that shows e.g.
product features with images in a nice boxed
layout (see screenshot from Bootstrap theme)
25
Adding a new content type
● If you do not already use your own schemas module,
create one, e.g. "com.mycompany.schemas"
● Create a new OpenCms XML Schema Definition
(XSD) file in the schemas/ folder of the module
26
Add a new content type
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
<xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd"/>
<xsd:include schemaLocation="opencms://system/.../schemas/nested/featureitem.xsd"/>
<xsd:element name="MyCompanyFeatures" type="OpenCmsMyCompanyFeatures"/>
...
<xsd:complexType name="OpenCmsMyCompanyFeature">
<xsd:sequence>
<xsd:element name="Title" type="OpenCmsString" />
<xsd:element name="Item" type="OpenCmsMyCompanyFeatureItem" minOccurs="3" maxOccurs="4" />
</xsd:sequence>
<xsd:attribute name="language" type="OpenCmsLocale" use="required"/>
</xsd:complexType>
...
● Upload file icons (a small 16x16 version for the
workplace, a 24x24 version for the content
editor) for the new type to the folder
/system/workplace/resources/filetypes/
● Add these file icons to the module resources to
ensure they are exported together with the
module
27
Add a new content type
● Stop the servlet container and add the resource
type definition to the module in the "opencms-
modules.xml" configuration file
28
Add a new content type
<module>
<name>com.mycompany.schemas</name>
...
<parameters/>
<resourcetypes>
<type class="org.opencms.file.types.CmsResourceTypeXmlContent" name="my-feature" id="33333">
<param name="schema">/system/modules/com.mycompany.schemas/schemas/feature.xsd</param>
</type>
</resourcetypes>
<explorertypes>
<explorertype name="my-feature" key="fileicon.my-feature" icon="my-feature.png" bigicon="my-feature_big.png"
reference="xmlcontent">
<newresource page="structurecontent" uri="newresource_xmlcontent.jsp?newresourcetype=my-feature"
order="130" autosetnavigation="false" autosettitle="false" info="desc.my-feature"/>
</explorertype>
</explorertypes>
</module>
● Create a formatter JSP file that renders the
elements of the new content type
● Configure the resource type either in the
module configuration for system wide usage or
in the subsite configuration file
29
Add a new content type
● Localize the editor elements and eventual
frontend output
30
Add a new content type
● Resulting feature content in OpenCms
31
Add a new content type
● Live Demo
32
Live Demo
Demo
Demo Demo
Demo
デモ
● Any Questions?
33
Any Questions?
Fragen?
Questions ?
Questiones?
¿Preguntas?質問
Andreas Zahner
Alkacon Software GmbH
http://www.alkacon.com
http://www.opencms.org
Thank you very much for your
attention!
34

More Related Content

What's hot

OpenCms Days 2014 - Enhancing OpenCms front end development with Sass and Grunt
OpenCms Days 2014 - Enhancing OpenCms front end development with Sass and GruntOpenCms Days 2014 - Enhancing OpenCms front end development with Sass and Grunt
OpenCms Days 2014 - Enhancing OpenCms front end development with Sass and GruntAlkacon Software GmbH & Co. KG
 
OpenCms Days 2015 Creating Apps for the OpenCms 10 workplace
OpenCms Days 2015  Creating Apps for the OpenCms 10 workplace OpenCms Days 2015  Creating Apps for the OpenCms 10 workplace
OpenCms Days 2015 Creating Apps for the OpenCms 10 workplace Alkacon Software GmbH & Co. KG
 
OpenCms Days 2016: Next generation content repository
OpenCms Days 2016: Next generation content repository OpenCms Days 2016: Next generation content repository
OpenCms Days 2016: Next generation content repository Alkacon Software GmbH & Co. KG
 
OpenCms Days 2016: OpenCms at the swiss seismological service
OpenCms Days 2016: OpenCms at the swiss seismological serviceOpenCms Days 2016: OpenCms at the swiss seismological service
OpenCms Days 2016: OpenCms at the swiss seismological serviceAlkacon Software GmbH & Co. KG
 
Drupal training-1-in-mumbai
Drupal training-1-in-mumbaiDrupal training-1-in-mumbai
Drupal training-1-in-mumbaivibrantuser
 
OpenCms Days 2014 - OpenCms content editor and pdf extensions
OpenCms Days 2014 - OpenCms content editor and pdf extensionsOpenCms Days 2014 - OpenCms content editor and pdf extensions
OpenCms Days 2014 - OpenCms content editor and pdf extensionsAlkacon Software GmbH & Co. KG
 
OVERVIEW: Chromium Source Tree
OVERVIEW: Chromium Source TreeOVERVIEW: Chromium Source Tree
OVERVIEW: Chromium Source TreeChang W. Doh
 
Introduction to Moodle Development
Introduction to Moodle DevelopmentIntroduction to Moodle Development
Introduction to Moodle Developmentmoorejon
 
HTML, CSS & Javascript Architecture (extended version) - Jan Kraus
HTML, CSS & Javascript Architecture (extended version) - Jan KrausHTML, CSS & Javascript Architecture (extended version) - Jan Kraus
HTML, CSS & Javascript Architecture (extended version) - Jan KrausWomen in Technology Poland
 
Openbit szkolenie-drupal-podstawy 2
Openbit szkolenie-drupal-podstawy 2Openbit szkolenie-drupal-podstawy 2
Openbit szkolenie-drupal-podstawy 2Grzegorz Bartman
 
Szkolenie drupal-podstawy 2
Szkolenie drupal-podstawy 2Szkolenie drupal-podstawy 2
Szkolenie drupal-podstawy 2Grzegorz Bartman
 
Extending JBoss EPP and Site Publisher your way
Extending JBoss EPP and Site Publisher your wayExtending JBoss EPP and Site Publisher your way
Extending JBoss EPP and Site Publisher your wayrafaelliu
 
Architektura html, css i javascript - Jan Kraus
Architektura html, css i javascript - Jan KrausArchitektura html, css i javascript - Jan Kraus
Architektura html, css i javascript - Jan KrausWomen in Technology Poland
 
The OpenEuropa Initiative
The OpenEuropa InitiativeThe OpenEuropa Initiative
The OpenEuropa InitiativeNuvole
 

What's hot (20)

OpenCms Days 2014 - Enhancing OpenCms front end development with Sass and Grunt
OpenCms Days 2014 - Enhancing OpenCms front end development with Sass and GruntOpenCms Days 2014 - Enhancing OpenCms front end development with Sass and Grunt
OpenCms Days 2014 - Enhancing OpenCms front end development with Sass and Grunt
 
OpenCms Days 2015 Hidden features of OpenCms
OpenCms Days 2015 Hidden features of OpenCmsOpenCms Days 2015 Hidden features of OpenCms
OpenCms Days 2015 Hidden features of OpenCms
 
OpenCms Days 2015 Creating Apps for the OpenCms 10 workplace
OpenCms Days 2015  Creating Apps for the OpenCms 10 workplace OpenCms Days 2015  Creating Apps for the OpenCms 10 workplace
OpenCms Days 2015 Creating Apps for the OpenCms 10 workplace
 
OpenCms Days 2013 - Site Management Tool
OpenCms Days 2013 - Site Management ToolOpenCms Days 2013 - Site Management Tool
OpenCms Days 2013 - Site Management Tool
 
OpenCms Days 2016: Next generation content repository
OpenCms Days 2016: Next generation content repository OpenCms Days 2016: Next generation content repository
OpenCms Days 2016: Next generation content repository
 
OpenCms Days 2015 Advanced Solr Searching
OpenCms Days 2015 Advanced Solr SearchingOpenCms Days 2015 Advanced Solr Searching
OpenCms Days 2015 Advanced Solr Searching
 
OpenCms Days 2015 Next generation repository
OpenCms Days 2015  Next generation repositoryOpenCms Days 2015  Next generation repository
OpenCms Days 2015 Next generation repository
 
OpenCms Days 2016: OpenCms at the swiss seismological service
OpenCms Days 2016: OpenCms at the swiss seismological serviceOpenCms Days 2016: OpenCms at the swiss seismological service
OpenCms Days 2016: OpenCms at the swiss seismological service
 
OpenCms Days 2015 How do you develop for OpenCms?
OpenCms Days 2015 How do you develop for OpenCms?OpenCms Days 2015 How do you develop for OpenCms?
OpenCms Days 2015 How do you develop for OpenCms?
 
Drupal training-1-in-mumbai
Drupal training-1-in-mumbaiDrupal training-1-in-mumbai
Drupal training-1-in-mumbai
 
OpenCms Days 2014 - OpenCms content editor and pdf extensions
OpenCms Days 2014 - OpenCms content editor and pdf extensionsOpenCms Days 2014 - OpenCms content editor and pdf extensions
OpenCms Days 2014 - OpenCms content editor and pdf extensions
 
OVERVIEW: Chromium Source Tree
OVERVIEW: Chromium Source TreeOVERVIEW: Chromium Source Tree
OVERVIEW: Chromium Source Tree
 
Introduction to Moodle Development
Introduction to Moodle DevelopmentIntroduction to Moodle Development
Introduction to Moodle Development
 
HTML, CSS & Javascript Architecture (extended version) - Jan Kraus
HTML, CSS & Javascript Architecture (extended version) - Jan KrausHTML, CSS & Javascript Architecture (extended version) - Jan Kraus
HTML, CSS & Javascript Architecture (extended version) - Jan Kraus
 
Openbit szkolenie-drupal-podstawy 2
Openbit szkolenie-drupal-podstawy 2Openbit szkolenie-drupal-podstawy 2
Openbit szkolenie-drupal-podstawy 2
 
Szkolenie drupal-podstawy 2
Szkolenie drupal-podstawy 2Szkolenie drupal-podstawy 2
Szkolenie drupal-podstawy 2
 
Extending JBoss EPP and Site Publisher your way
Extending JBoss EPP and Site Publisher your wayExtending JBoss EPP and Site Publisher your way
Extending JBoss EPP and Site Publisher your way
 
How Browsers Work
How Browsers Work How Browsers Work
How Browsers Work
 
Architektura html, css i javascript - Jan Kraus
Architektura html, css i javascript - Jan KrausArchitektura html, css i javascript - Jan Kraus
Architektura html, css i javascript - Jan Kraus
 
The OpenEuropa Initiative
The OpenEuropa InitiativeThe OpenEuropa Initiative
The OpenEuropa Initiative
 

Viewers also liked

OpenCms Days 2013 - Gradle based OpenCms build automated setup
OpenCms Days 2013 - Gradle based OpenCms build automated setupOpenCms Days 2013 - Gradle based OpenCms build automated setup
OpenCms Days 2013 - Gradle based OpenCms build automated setupAlkacon Software GmbH & Co. KG
 
OpenCmsDays 2013 - Using OpenCms 9 folders as a network drive
OpenCmsDays 2013 - Using OpenCms 9 folders as a network driveOpenCmsDays 2013 - Using OpenCms 9 folders as a network drive
OpenCmsDays 2013 - Using OpenCms 9 folders as a network driveAlkacon Software GmbH & Co. KG
 
これからのCMSマーケットトレンドとPHP (for fukuoka.php)
これからのCMSマーケットトレンドとPHP (for fukuoka.php)これからのCMSマーケットトレンドとPHP (for fukuoka.php)
これからのCMSマーケットトレンドとPHP (for fukuoka.php)株式会社ミツエーリンクス
 
OpenCms Days 2013 - Outsourcing OpenCms Template Design
OpenCms Days 2013 - Outsourcing OpenCms Template DesignOpenCms Days 2013 - Outsourcing OpenCms Template Design
OpenCms Days 2013 - Outsourcing OpenCms Template DesignAlkacon Software GmbH & Co. KG
 
OpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMIS
OpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMISOpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMIS
OpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMISAlkacon Software GmbH & Co. KG
 
OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...
OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...
OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...Alkacon Software GmbH & Co. KG
 
OpenCms Days 2014 - Introducing the 9.5 OpenCms documentation
OpenCms Days 2014 - Introducing the 9.5 OpenCms documentationOpenCms Days 2014 - Introducing the 9.5 OpenCms documentation
OpenCms Days 2014 - Introducing the 9.5 OpenCms documentationAlkacon Software GmbH & Co. KG
 
Eurelis - Construire une usine à sites
Eurelis - Construire une usine à sitesEurelis - Construire une usine à sites
Eurelis - Construire une usine à sitesAgence-Eurelis
 
Internal and external business environment
Internal and external business environmentInternal and external business environment
Internal and external business environmentAashish Sahi
 

Viewers also liked (15)

OpenCms Days 2015 OpenCms X marks the spot
OpenCms Days 2015 OpenCms X marks the spotOpenCms Days 2015 OpenCms X marks the spot
OpenCms Days 2015 OpenCms X marks the spot
 
OpenCms Days 2013 - OpenCms Partner Program
OpenCms Days 2013 - OpenCms Partner ProgramOpenCms Days 2013 - OpenCms Partner Program
OpenCms Days 2013 - OpenCms Partner Program
 
OpenCms Days 2012 - Developing OpenCms with Gradle
OpenCms Days 2012 - Developing OpenCms with GradleOpenCms Days 2012 - Developing OpenCms with Gradle
OpenCms Days 2012 - Developing OpenCms with Gradle
 
OpenCms Days 2013 - Gradle based OpenCms build automated setup
OpenCms Days 2013 - Gradle based OpenCms build automated setupOpenCms Days 2013 - Gradle based OpenCms build automated setup
OpenCms Days 2013 - Gradle based OpenCms build automated setup
 
OpenCmsDays 2013 - Using OpenCms 9 folders as a network drive
OpenCmsDays 2013 - Using OpenCms 9 folders as a network driveOpenCmsDays 2013 - Using OpenCms 9 folders as a network drive
OpenCmsDays 2013 - Using OpenCms 9 folders as a network drive
 
これからのCMSマーケットトレンドとPHP (for fukuoka.php)
これからのCMSマーケットトレンドとPHP (for fukuoka.php)これからのCMSマーケットトレンドとPHP (for fukuoka.php)
これからのCMSマーケットトレンドとPHP (for fukuoka.php)
 
OpenCms Days 2013 - Outsourcing OpenCms Template Design
OpenCms Days 2013 - Outsourcing OpenCms Template DesignOpenCms Days 2013 - Outsourcing OpenCms Template Design
OpenCms Days 2013 - Outsourcing OpenCms Template Design
 
OpenCms Days 2013 - Social Connect for OpenCms Portal
OpenCms Days 2013 - Social Connect for OpenCms PortalOpenCms Days 2013 - Social Connect for OpenCms Portal
OpenCms Days 2013 - Social Connect for OpenCms Portal
 
OpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMIS
OpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMISOpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMIS
OpenCms Days 2012 - OpenCms 8.5: Accessing the VFS repository using CMIS
 
OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...
OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...
OpenCms Days 2012 - How Software AG is optimizing workflows with OpenCms 8 an...
 
OpenCms Days 2015 OpenGovernment
OpenCms Days 2015 OpenGovernmentOpenCms Days 2015 OpenGovernment
OpenCms Days 2015 OpenGovernment
 
OpenCms Days 2016: Keynote - Introducing OpenCms 10.5
OpenCms Days 2016:   Keynote - Introducing OpenCms 10.5OpenCms Days 2016:   Keynote - Introducing OpenCms 10.5
OpenCms Days 2016: Keynote - Introducing OpenCms 10.5
 
OpenCms Days 2014 - Introducing the 9.5 OpenCms documentation
OpenCms Days 2014 - Introducing the 9.5 OpenCms documentationOpenCms Days 2014 - Introducing the 9.5 OpenCms documentation
OpenCms Days 2014 - Introducing the 9.5 OpenCms documentation
 
Eurelis - Construire une usine à sites
Eurelis - Construire une usine à sitesEurelis - Construire une usine à sites
Eurelis - Construire une usine à sites
 
Internal and external business environment
Internal and external business environmentInternal and external business environment
Internal and external business environment
 

Similar to OpenCms Days 2013 - Bootstrap your templates

Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)
Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)
Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)Roman Zenner
 
How to Write Custom Modules for PHP-based E-Commerce Systems (2011)
How to Write Custom Modules for PHP-based E-Commerce Systems (2011)How to Write Custom Modules for PHP-based E-Commerce Systems (2011)
How to Write Custom Modules for PHP-based E-Commerce Systems (2011)Roman Zenner
 
OpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve content
OpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve contentOpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve content
OpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve contentAlkacon Software GmbH & Co. KG
 
Social Connections VI — IBM Connections Extensions and Themes Demystified
Social Connections VI — IBM Connections Extensions and Themes DemystifiedSocial Connections VI — IBM Connections Extensions and Themes Demystified
Social Connections VI — IBM Connections Extensions and Themes DemystifiedClaudio Procida
 
Introduction to BOOTSTRAP
Introduction to BOOTSTRAPIntroduction to BOOTSTRAP
Introduction to BOOTSTRAPJeanie Arnoco
 
Custom gutenberg block development with React
Custom gutenberg block development with ReactCustom gutenberg block development with React
Custom gutenberg block development with ReactImran Sayed
 
Webpack Introduction
Webpack IntroductionWebpack Introduction
Webpack IntroductionAnjali Chawla
 
Thinking in Components
Thinking in ComponentsThinking in Components
Thinking in ComponentsAnton Ivanov
 
webpack introductionNotice Demystifyingf
webpack introductionNotice Demystifyingfwebpack introductionNotice Demystifyingf
webpack introductionNotice DemystifyingfMrVMNair
 
Twitter bootstrap training_session_ppt
Twitter bootstrap training_session_pptTwitter bootstrap training_session_ppt
Twitter bootstrap training_session_pptRadheshyam Kori
 
Blisstering drupal module development ppt v1.2
Blisstering drupal module development ppt v1.2Blisstering drupal module development ppt v1.2
Blisstering drupal module development ppt v1.2Anil Sagar
 
SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...
SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...
SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...Brian O'Gorman
 
Gutenberg (WidgiLabs Training Sessions)
Gutenberg  (WidgiLabs Training Sessions)Gutenberg  (WidgiLabs Training Sessions)
Gutenberg (WidgiLabs Training Sessions)Nuno Morgadinho
 
Web components - An Introduction
Web components - An IntroductionWeb components - An Introduction
Web components - An Introductioncherukumilli2
 
How Joomla! builds a webpage (annotated)
How Joomla! builds a webpage (annotated)How Joomla! builds a webpage (annotated)
How Joomla! builds a webpage (annotated)Randy Carey
 
MongoDB Days Silicon Valley: Building Applications with the MEAN Stack
MongoDB Days Silicon Valley: Building Applications with the MEAN StackMongoDB Days Silicon Valley: Building Applications with the MEAN Stack
MongoDB Days Silicon Valley: Building Applications with the MEAN StackMongoDB
 
Getting Healthy with Magnolia, Blossom and Spring
Getting Healthy with Magnolia, Blossom and SpringGetting Healthy with Magnolia, Blossom and Spring
Getting Healthy with Magnolia, Blossom and SpringMagnolia
 
Magento x codekit x sass x compass x skeleton responsive grid
Magento x codekit x sass x compass x skeleton responsive gridMagento x codekit x sass x compass x skeleton responsive grid
Magento x codekit x sass x compass x skeleton responsive gridArush Sehgal
 

Similar to OpenCms Days 2013 - Bootstrap your templates (20)

Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)
Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)
Modul-Entwicklung für Magento, OXID eShop und Shopware (2013)
 
How to Write Custom Modules for PHP-based E-Commerce Systems (2011)
How to Write Custom Modules for PHP-based E-Commerce Systems (2011)How to Write Custom Modules for PHP-based E-Commerce Systems (2011)
How to Write Custom Modules for PHP-based E-Commerce Systems (2011)
 
OpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve content
OpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve contentOpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve content
OpenCms Days 2012 - OpenCms 8.5: Using Apache Solr to retrieve content
 
Social Connections VI — IBM Connections Extensions and Themes Demystified
Social Connections VI — IBM Connections Extensions and Themes DemystifiedSocial Connections VI — IBM Connections Extensions and Themes Demystified
Social Connections VI — IBM Connections Extensions and Themes Demystified
 
Introduction to BOOTSTRAP
Introduction to BOOTSTRAPIntroduction to BOOTSTRAP
Introduction to BOOTSTRAP
 
Custom gutenberg block development with React
Custom gutenberg block development with ReactCustom gutenberg block development with React
Custom gutenberg block development with React
 
Webpack Introduction
Webpack IntroductionWebpack Introduction
Webpack Introduction
 
Thinking in Components
Thinking in ComponentsThinking in Components
Thinking in Components
 
webpack introductionNotice Demystifyingf
webpack introductionNotice Demystifyingfwebpack introductionNotice Demystifyingf
webpack introductionNotice Demystifyingf
 
Twitter bootstrap training_session_ppt
Twitter bootstrap training_session_pptTwitter bootstrap training_session_ppt
Twitter bootstrap training_session_ppt
 
Blisstering drupal module development ppt v1.2
Blisstering drupal module development ppt v1.2Blisstering drupal module development ppt v1.2
Blisstering drupal module development ppt v1.2
 
SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...
SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...
SHOW202: How to customize Lotus Quickr Templates Using HTML, Javascript and C...
 
The emerging world of mongo db csp
The emerging world of mongo db   cspThe emerging world of mongo db   csp
The emerging world of mongo db csp
 
Gutenberg (WidgiLabs Training Sessions)
Gutenberg  (WidgiLabs Training Sessions)Gutenberg  (WidgiLabs Training Sessions)
Gutenberg (WidgiLabs Training Sessions)
 
Web components - An Introduction
Web components - An IntroductionWeb components - An Introduction
Web components - An Introduction
 
How Joomla! builds a webpage (annotated)
How Joomla! builds a webpage (annotated)How Joomla! builds a webpage (annotated)
How Joomla! builds a webpage (annotated)
 
Liferay (DXP) 7 Tech Meetup for Developers
Liferay (DXP) 7 Tech Meetup for DevelopersLiferay (DXP) 7 Tech Meetup for Developers
Liferay (DXP) 7 Tech Meetup for Developers
 
MongoDB Days Silicon Valley: Building Applications with the MEAN Stack
MongoDB Days Silicon Valley: Building Applications with the MEAN StackMongoDB Days Silicon Valley: Building Applications with the MEAN Stack
MongoDB Days Silicon Valley: Building Applications with the MEAN Stack
 
Getting Healthy with Magnolia, Blossom and Spring
Getting Healthy with Magnolia, Blossom and SpringGetting Healthy with Magnolia, Blossom and Spring
Getting Healthy with Magnolia, Blossom and Spring
 
Magento x codekit x sass x compass x skeleton responsive grid
Magento x codekit x sass x compass x skeleton responsive gridMagento x codekit x sass x compass x skeleton responsive grid
Magento x codekit x sass x compass x skeleton responsive grid
 

More from Alkacon Software GmbH & Co. KG

OpenCms Days 2016: Participation and transparency portals with OpenCms
OpenCms Days 2016: Participation and transparency portals with OpenCmsOpenCms Days 2016: Participation and transparency portals with OpenCms
OpenCms Days 2016: Participation and transparency portals with OpenCmsAlkacon Software GmbH & Co. KG
 
OpenCms Days 2014 - How Techem handles international customer portals
OpenCms Days 2014 - How Techem handles international customer portalsOpenCms Days 2014 - How Techem handles international customer portals
OpenCms Days 2014 - How Techem handles international customer portalsAlkacon Software GmbH & Co. KG
 
OpenCms Days 2014 - OpenCms cloud setup with the FI-TS
OpenCms Days 2014 - OpenCms cloud setup with the FI-TSOpenCms Days 2014 - OpenCms cloud setup with the FI-TS
OpenCms Days 2014 - OpenCms cloud setup with the FI-TSAlkacon Software GmbH & Co. KG
 
OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...
OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...
OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...Alkacon Software GmbH & Co. KG
 
OpenCms Days 2014 - User Generated Content in OpenCms 9.5
OpenCms Days 2014 - User Generated Content in OpenCms 9.5OpenCms Days 2014 - User Generated Content in OpenCms 9.5
OpenCms Days 2014 - User Generated Content in OpenCms 9.5Alkacon Software GmbH & Co. KG
 

More from Alkacon Software GmbH & Co. KG (12)

OpenCms Days 2016: Participation and transparency portals with OpenCms
OpenCms Days 2016: Participation and transparency portals with OpenCmsOpenCms Days 2016: Participation and transparency portals with OpenCms
OpenCms Days 2016: Participation and transparency portals with OpenCms
 
OpenCms Days 2015 OCEE explained
OpenCms Days 2015 OCEE explainedOpenCms Days 2015 OCEE explained
OpenCms Days 2015 OCEE explained
 
OpenCms Days 2015 OpenCms at erarta
OpenCms Days 2015 OpenCms at erarta OpenCms Days 2015 OpenCms at erarta
OpenCms Days 2015 OpenCms at erarta
 
OpenCms Days 2015 Arkema, a leading chemicals company
OpenCms Days 2015 Arkema, a leading chemicals companyOpenCms Days 2015 Arkema, a leading chemicals company
OpenCms Days 2015 Arkema, a leading chemicals company
 
OpenCms Days 2014 - How Techem handles international customer portals
OpenCms Days 2014 - How Techem handles international customer portalsOpenCms Days 2014 - How Techem handles international customer portals
OpenCms Days 2014 - How Techem handles international customer portals
 
OpenCms Days 2014 - OpenCms cloud setup with the FI-TS
OpenCms Days 2014 - OpenCms cloud setup with the FI-TSOpenCms Days 2014 - OpenCms cloud setup with the FI-TS
OpenCms Days 2014 - OpenCms cloud setup with the FI-TS
 
OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...
OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...
OpenCms Days 2014 - OpenCms Module Development and Deployment with IntelliJ, ...
 
OpenCms Days 2014 - OpenCms 9 - A video tube?
OpenCms Days 2014 - OpenCms 9 - A video tube?OpenCms Days 2014 - OpenCms 9 - A video tube?
OpenCms Days 2014 - OpenCms 9 - A video tube?
 
OpenCms Days 2014 - User Generated Content in OpenCms 9.5
OpenCms Days 2014 - User Generated Content in OpenCms 9.5OpenCms Days 2014 - User Generated Content in OpenCms 9.5
OpenCms Days 2014 - User Generated Content in OpenCms 9.5
 
OpenCms Days 2014 - Updating to OpenCms 9.5
OpenCms Days 2014 - Updating to OpenCms 9.5OpenCms Days 2014 - Updating to OpenCms 9.5
OpenCms Days 2014 - Updating to OpenCms 9.5
 
OpenCms Days 2014 - Using the SOLR collector
OpenCms Days 2014 - Using the SOLR collectorOpenCms Days 2014 - Using the SOLR collector
OpenCms Days 2014 - Using the SOLR collector
 
OpenCms Days 2014 Keynote - Step up to OpenCms 9.5
OpenCms Days 2014 Keynote - Step up to OpenCms 9.5OpenCms Days 2014 Keynote - Step up to OpenCms 9.5
OpenCms Days 2014 Keynote - Step up to OpenCms 9.5
 

Recently uploaded

Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireExakis Nelite
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfSrushith Repakula
 
ADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxFIDO Alliance
 
2024 May Patch Tuesday
2024 May Patch Tuesday2024 May Patch Tuesday
2024 May Patch TuesdayIvanti
 
AI mind or machine power point presentation
AI mind or machine power point presentationAI mind or machine power point presentation
AI mind or machine power point presentationyogeshlabana357357
 
JavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate GuideJavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate GuidePixlogix Infotech
 
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdfFrisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdfAnubhavMangla3
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctBrainSell Technologies
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe中 央社
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityVictorSzoltysek
 
Working together SRE & Platform Engineering
Working together SRE & Platform EngineeringWorking together SRE & Platform Engineering
Working together SRE & Platform EngineeringMarcus Vechiato
 
Event-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream ProcessingEvent-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream ProcessingScyllaDB
 
Generative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfGenerative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfalexjohnson7307
 
Design Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxDesign Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxFIDO Alliance
 
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Skynet Technologies
 
Syngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdfSyngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdfSyngulon
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfdanishmna97
 
Top 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development CompaniesTop 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development CompaniesTopCSSGallery
 

Recently uploaded (20)

Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - Questionnaire
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdf
 
ADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptx
 
2024 May Patch Tuesday
2024 May Patch Tuesday2024 May Patch Tuesday
2024 May Patch Tuesday
 
AI mind or machine power point presentation
AI mind or machine power point presentationAI mind or machine power point presentation
AI mind or machine power point presentation
 
JavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate GuideJavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate Guide
 
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdfFrisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage Intacct
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps Productivity
 
Working together SRE & Platform Engineering
Working together SRE & Platform EngineeringWorking together SRE & Platform Engineering
Working together SRE & Platform Engineering
 
Event-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream ProcessingEvent-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream Processing
 
Generative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfGenerative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdf
 
Design Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxDesign Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptx
 
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
 
Syngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdfSyngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdf
 
Overview of Hyperledger Foundation
Overview of Hyperledger FoundationOverview of Hyperledger Foundation
Overview of Hyperledger Foundation
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cf
 
Top 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development CompaniesTop 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development Companies
 

OpenCms Days 2013 - Bootstrap your templates

  • 1. Andreas Zahner, Alkacon Software Workshop Track Bootstrap your templates with OpenCms 9 09.10.2013
  • 2. ● The OpenCms 9 Bootstrap template ● Module structure ● Content containers ● Available content types ● Cloning OpenCms modules ● How to clone a module ● Customizing the cloned module ● Using another Bootstrap theme ● Modifying the formatter HTML output ● Creating pages using the customized formatters ● Add a new content type 2 Agenda
  • 3. ● Module Structure of previous OpenCms versions: ● One Template module ● For each resource type, an extra module has been developed including the type definition, XSDs, localization and formatters ● OpenCms 9 Bootstrap template: ● Only 2 modules contain the template and all necessary functionality for the website ● Reason: cloning the modules using the integrated functions is easier and faster 3 Bootstrap template - Structure
  • 4. ● Schemas module (com.alkacon.bootstrap.schemas) ● This module contains everything for the definition of the available content elements ● Resource type definitions ● XSD files ● Localization bundles 4 Bootstrap template - Structure
  • 5. ● Formatters module (com.alkacon.bootstrap.formatters) ● This module contains all components that are used for the website frontend output ● Main template ● Template resources ● JSP elements for the template (e.g. navigation) ● Dynamic functions (e.g. Login box) ● Formatters for all types of schema module 5 Bootstrap template - Structure
  • 6. ● The bootstrap template has 5 content containers ● Top container ● For full width content ● Middle left container, middle right container ● The column ratio can be adjusted using a property Example: 9 – 3: left column uses 9 grid units, the right column uses 3 grid units (the default setting) ● Bottom container ● For full width content ● Foot container ● Only used for sticky footers (i.e. flexible content) 6 Bootstrap template - Containers
  • 7. 7 Bootstrap template - Containers ● Screenshot of container structure
  • 8. ● Currently available content types: ● Flexible Content ● Image Row ● Hero / Jumbotron ● News Article ● Product ● Slider ● Tabs / Accordion ● Text Block 8 Bootstrap template - Types
  • 9. ● Advantages of cloning the shipped modules ● Fast and easy project start (no need to start with "Adam & Eve") ● Use existing content types with different HTML output ● Modify the page template by using ● A different container structure (optional) ● A different Bootstrap theme (optional) ● Clone existing content types and modify their fields according to your requirements 9 Cloning OpenCms modules
  • 10. ● Use the dynamic function "Clone a module" that is part of the demo formatter module for clone operations 10 Cloning OpenCms modules
  • 11. ● The function form uses the Java bean "CmsCloneModule" of the OpenCms core package "org.opencms.workplace.tools.modules" ● getter and setter methods for all configurable options ● executeModuleClone() starts the clone process ● The module is copied first ● Internal references are adjusted in the copied module ● The module is added to the OpenCms module configuration ● Optionally, the site contents references can be adjusted to use the new module clone 11 Cloning OpenCms modules
  • 12. ● Clone the formatter module (1) ● Select the source formatters module from the drop down list ● Be sure to uncheck the delete option if you want to keep the old module in the system ● Enter the new module and author information ● Be sure that the package name of the module does not exist yet ● For our examples, we create a clone named "com.mycompany.formatters" 12 Cloning OpenCms modules
  • 13. ● Clone the formatter module (2) ● Translation options are only important when cloning a module containing resource type definitions ● Source and target prefix names: If the resource types of the module have a prefix (like "bs"), this will be replaced by the target prefix name ● The Formatters source module has to be entered to ensure that the XSD files reference the correct formatter JSPs after cloning all required modules ● Uncheck the option to replace schema locations and resource types when cloning the formatters module (i.e. without resource types) 13 Cloning OpenCms modules
  • 14. ● After cloning, the new module is shown in the Module Management view ● The resources of the cloned module can be checked below the /system/modules/ folder of the root site ● If a module with resource type definitions was cloned, the servlet container has to be restarted 14 Cloning OpenCms modules
  • 15. ● Live Demo 15 Live Demo Demo Demo Demo Demo デモ
  • 16. ● Switching to another ready to use Bootstrap theme ● All theme specific files (CSS, JavaScript, images) are placed inside the resources/ folder of the formatter module ● Delete all these files and replace them with the necessary files of the theme you want to use 16 Customizing the cloned module
  • 17. ● Switching to another ready to use Bootstrap theme ● Edit the template JSP to use the correct CSS and JS files of the theme ● Adjust the HTML output of the template JSP according to the requirements of the new theme (if required) 17 Customizing the cloned module
  • 18. ... <head> ... <cms:headincludes type="css" closetags="true" defaults="%(link.weak:/system/modules/com.mycompany.formatters/resources/css/bootstrap.min.c ss) |%(link.weak:/system/modules/com.mycompany.formatters/resources/css/bootstrap- responsive.min.css) |%(link.weak:/system/modules/com.mycompany.formatters/resources/css/bootstrap- overrides.css) ... |%(link.weak:/system/modules/com.mycompany.formatters/resources/css/page.css)" /> ... <cms:headincludes type="javascript" defaults="http://code.jquery.com/jquery-latest.js |%(link.weak:/system/modules/com.mycompany.formatters/resources/js/bootstrap.min.js) |%(link.weak:/system/modules/com.mycompany.formatters/resources/js/theme.js)" /> ... </head><body> ... 18 Customizing the cloned module
  • 19. ● Change the HTML output of the template element JSPs (e.g. main navigation) for the new theme 19 Customizing the cloned module <div class="navbar"> <div class="navbar-inner"> <a class="btn btn-navbar" data- toggle="collapse" data-target=".nav- collapse"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </a><!-- /nav-collapse --> <div class="nav-collapse collapse"> <ul class="nav top-2"> ... <div class="navbar navbar-inverse navbar- static-top"> <div class="navbar-inner"><div class="container"> <a class="btn btn-navbar" data- toggle="collapse" data-target=".nav- collapse"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </a><!-- /nav-collapse --> <a class="brand" href="index.html"><strong>My Company</strong></a> <div class="nav-collapse collapse"> <ul class="nav pull-right">
  • 20. ● Change the HTML output of the formatter JSPs (e.g. text block) for the new theme 20 Customizing the cloned module ... <cms:formatter var="content"> ... <c:if test="${paragraph.value.Headline.isSet}"> <div class="headline"><h3>${paragraph.rdfa.Hea dline}>${paragraph.value.Headline}</h3></ div> </c:if> ... <c:if test="${paragraph.value.Link.exists}"> <p><a class="btn-u btn-u-small" href="<cms:link>${paragraph.value.Link.va lue.URI}</cms:link>">${paragraph.value.Li nk.value.Text}</a></p> </c:if> ... ... <cms:formatter var="content"> ... <c:if test="${paragraph.value.Headline.isSet}"> <div class="section_header"><h3>${paragraph.rd fa.Headline}>${paragraph.value.Headline}< /h3></div> </c:if> ... <c:if test="${paragraph.value.Link.exists}"> <p><a class="btn btn-small" href="<cms:link>${paragraph.value.Link.va lue.URI}</cms:link>">${paragraph.value.Li nk.value.Text}</a></p> </c:if> ...
  • 21. ● Create a subsite that uses your cloned template and formatters ● Set the "template" property value on the subsite folder to your template JSP, e.g. "/system/modules/com.mycompany.formatters/tem plates/bootstrap-page.jsp" 21 Customizing the cloned module
  • 22. ● Edit the subsite configuration to make the content types use the correct formatter JSPs if only the formatter module was cloned 22 Customizing the cloned module
  • 23. ● After these steps, you can start creating your pages with the cloned template and formatters 23 Customizing the cloned module
  • 24. ● Live Demo 24 Live Demo Demo Demo Demo Demo デモ
  • 25. ● Add a new content type that you need for your website ● Example: Feature content that shows e.g. product features with images in a nice boxed layout (see screenshot from Bootstrap theme) 25 Adding a new content type
  • 26. ● If you do not already use your own schemas module, create one, e.g. "com.mycompany.schemas" ● Create a new OpenCms XML Schema Definition (XSD) file in the schemas/ folder of the module 26 Add a new content type <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> <xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd"/> <xsd:include schemaLocation="opencms://system/.../schemas/nested/featureitem.xsd"/> <xsd:element name="MyCompanyFeatures" type="OpenCmsMyCompanyFeatures"/> ... <xsd:complexType name="OpenCmsMyCompanyFeature"> <xsd:sequence> <xsd:element name="Title" type="OpenCmsString" /> <xsd:element name="Item" type="OpenCmsMyCompanyFeatureItem" minOccurs="3" maxOccurs="4" /> </xsd:sequence> <xsd:attribute name="language" type="OpenCmsLocale" use="required"/> </xsd:complexType> ...
  • 27. ● Upload file icons (a small 16x16 version for the workplace, a 24x24 version for the content editor) for the new type to the folder /system/workplace/resources/filetypes/ ● Add these file icons to the module resources to ensure they are exported together with the module 27 Add a new content type
  • 28. ● Stop the servlet container and add the resource type definition to the module in the "opencms- modules.xml" configuration file 28 Add a new content type <module> <name>com.mycompany.schemas</name> ... <parameters/> <resourcetypes> <type class="org.opencms.file.types.CmsResourceTypeXmlContent" name="my-feature" id="33333"> <param name="schema">/system/modules/com.mycompany.schemas/schemas/feature.xsd</param> </type> </resourcetypes> <explorertypes> <explorertype name="my-feature" key="fileicon.my-feature" icon="my-feature.png" bigicon="my-feature_big.png" reference="xmlcontent"> <newresource page="structurecontent" uri="newresource_xmlcontent.jsp?newresourcetype=my-feature" order="130" autosetnavigation="false" autosettitle="false" info="desc.my-feature"/> </explorertype> </explorertypes> </module>
  • 29. ● Create a formatter JSP file that renders the elements of the new content type ● Configure the resource type either in the module configuration for system wide usage or in the subsite configuration file 29 Add a new content type
  • 30. ● Localize the editor elements and eventual frontend output 30 Add a new content type
  • 31. ● Resulting feature content in OpenCms 31 Add a new content type
  • 32. ● Live Demo 32 Live Demo Demo Demo Demo Demo デモ
  • 33. ● Any Questions? 33 Any Questions? Fragen? Questions ? Questiones? ¿Preguntas?質問
  • 34. Andreas Zahner Alkacon Software GmbH http://www.alkacon.com http://www.opencms.org Thank you very much for your attention! 34