SlideShare ist ein Scribd-Unternehmen logo
1 von 33
Downloaden Sie, um offline zu lesen
Getting Plone Ready for the Prom - Clayton Parker                                  03.12.2008




                       Getting Plone Ready
                          for the Prom
                                            Plone Symposium East 2008
                                                  Clayton Parker
                                                  March 12, 2008




  Six Feet Up, Inc. • http://www.sixfeetup.com                          Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                          03.12.2008




                                                    Who Am I?


                 •       Plone developer since 2003
                 •       Lead Developer at Six Feet Up, Inc.
                 •       All around nice guy :)




  Six Feet Up, Inc. • http://www.sixfeetup.com                  Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                  03.12.2008




                                  What are we in for?


                 •       Approaches to skinning Plone
                 •       Tools used
                 •       Advanced techniques




  Six Feet Up, Inc. • http://www.sixfeetup.com          Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                        03.12.2008




                                             Where to start


                 •      Debug mode
                 •      $INSTANCE_HOME/bin/zopectl fg
                 •      $buildout/bin/instance fg
                 •      zope.conf
                       • debug-mode on



  Six Feet Up, Inc. • http://www.sixfeetup.com                Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                 03.12.2008




                                    More debug modes


                 •       portal_css
                 •       portal_javascripts
                 •       portal_kss




  Six Feet Up, Inc. • http://www.sixfeetup.com         Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                    03.12.2008




                                      Get to know Plone




  Six Feet Up, Inc. • http://www.sixfeetup.com            Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                    03.12.2008




                                      Get to know Plone




  Six Feet Up, Inc. • http://www.sixfeetup.com            Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                   03.12.2008




                                  Theories of Skinning



                 •       Light Skinning
                 •       use base_properties




  Six Feet Up, Inc. • http://www.sixfeetup.com           Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                                                                                    03.12.2008




                                          base_properties
                                        title:string=Plone's color, font, logo and border defaults

                                        plone_skin:string=Plone Default

                                        logoName:string=logo.jpg

                                        fontFamily:string=quot;Lucida Grandequot;,Verdana, Lucida, Helvetica, Arial, sans-serif
                                        fontBaseSize:string=69%
                                        fontColor:string=Black
                                        fontSmallSize:string=90%

                                        backgroundColor:string=White

                                        linkColor:string=#436976
                                        linkActiveColor:string=Red
                                        linkVisitedColor:string=Purple

                                        borderWidth:string=1px
                                        borderStyle:string=solid
                                        borderStyleAnnotations:string=solid



  Six Feet Up, Inc. • http://www.sixfeetup.com                                                                            Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                                                                              03.12.2008




                                                      css.dtml?



                                  /* <dtml-with base_properties> (do not remove this :) */
                                  /* <dtml-call quot;REQUEST.set('portal_url', portal_url())quot;> (not this either :) */




  Six Feet Up, Inc. • http://www.sixfeetup.com                                                                      Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                                                                            03.12.2008




                                     Example in the wild
                                                 body {
                                                    font: &dtml-fontBaseSize; <dtml-var fontFamily>;
                                                    background-color: &dtml-backgroundColor;;
                                                    color: &dtml-fontColor;;
                                                    margin: 0;
                                                    padding: 0;
                                                 }
                                                 table {
                                                    font-size: 100%;
                                                 }
                                                 a{
                                                    color: &dtml-linkColor;;
                                                    background-color: transparent;
                                                 }
                                                 img {                                                 pulled from
                                                    border: none;                                      base.css.dtml
                                                    vertical-align: middle;
                                                 }
                                                 p{
                                                    margin: 0 0 0.75em 0;
                                                    line-height: 1.5em;
                                                 }



  Six Feet Up, Inc. • http://www.sixfeetup.com                                                                    Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                   03.12.2008




                                  Building on the base



                 •       ploneCustom.css
                 •       override plone styles




  Six Feet Up, Inc. • http://www.sixfeetup.com           Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                       03.12.2008




                                         Going all the way



                 •       Clean the slate
                 •       Leave just authoring.css




  Six Feet Up, Inc. • http://www.sixfeetup.com               Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                          03.12.2008




                                                    TTW vs FS




  Six Feet Up, Inc. • http://www.sixfeetup.com                  Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                   03.12.2008




                                    Now I’m convinced.


                 •       DIYPloneStyle
                 •       ZopeSkel
                 •       GenericSetup




  Six Feet Up, Inc. • http://www.sixfeetup.com           Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                   03.12.2008




                                   Resource registries



                 •       portal_css
                 •       portal_javascripts




  Six Feet Up, Inc. • http://www.sixfeetup.com           Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                   03.12.2008




                                   Resource registries




  Six Feet Up, Inc. • http://www.sixfeetup.com           Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                03.12.2008




                                Advanced techniques




  Six Feet Up, Inc. • http://www.sixfeetup.com        Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                         03.12.2008




                                                    Viewlets



                 •       New to Plone 3
                 •       More control over the main_template




  Six Feet Up, Inc. • http://www.sixfeetup.com                 Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker              03.12.2008




                     Using @@manage-viewlets




  Six Feet Up, Inc. • http://www.sixfeetup.com      Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker              03.12.2008




                     Using @@manage-viewlets




  Six Feet Up, Inc. • http://www.sixfeetup.com      Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker              03.12.2008




                     Using @@manage-viewlets




  Six Feet Up, Inc. • http://www.sixfeetup.com      Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                       03.12.2008




                                                    Layers
  from plone.theme.interfaces import IDefaultPloneLayer

  class IThemeSpecific(IDefaultPloneLayer):
     quot;quot;quot;Marker interface that defines a Zope 3 browser layer.
       If you need to register a viewlet only for the
       quot;examplequot; theme, this interface must be its layer
       (in theme/viewlets/configure.zcml).
     quot;quot;quot;


  Six Feet Up, Inc. • http://www.sixfeetup.com               Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                       03.12.2008




                                                    Layers

  <interface
     interface=quot;.interfaces.IThemeSpecificquot;
     type=quot;zope.publisher.interfaces.browser.IBrowserSkinTypequot;
     name=quot;examplequot;
     />




  Six Feet Up, Inc. • http://www.sixfeetup.com               Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                        03.12.2008




                                           Moving viewlets

  <browser:viewlet
    name=quot;plone.abovecontenttitle.documentactionsquot;
    manager=quot;plone.app.layout.viewlets.interfaces.IAboveContentTitlequot;
    class=quot;plone.app.layout.viewlets.content.DocumentActionsViewletquot;
    permission=quot;zope2.Viewquot;
    layer=quot;.interfaces.IThemeSpecificquot;
    />




  Six Feet Up, Inc. • http://www.sixfeetup.com                Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                          03.12.2008




                                     Overriding viewlets

   <browser:viewlet
     name=quot;plone.footerquot;
     for=quot;*quot;
     manager=quot;plone.app.layout.viewlets.interfaces.IPortalFooterquot;
     template=quot;mytheme_footer.ptquot;
     permission=quot;zope.Publicquot;
     layer= quot;.interfaces.IThemeSpecificquot;
     />




  Six Feet Up, Inc. • http://www.sixfeetup.com                  Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                                03.12.2008




                                                    z3c.jbot

                    eggs = z3c.jbot
                    zcml = z3c.jbot-meta

                    <browser:templateOverrides directory=quot;templatesquot; />

                    templates/plone.app.layout.viewlets.footer.pt




  Six Feet Up, Inc. • http://www.sixfeetup.com                        Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                     03.12.2008




                                     Overriding portlets


     <plone:portletRenderer
      portlet=quot;plone.app.portlets.portlets.news.INewsPortletquot;
      template=quot;mytheme_news.ptquot;
      layer=quot;.interfaces.IThemeSpecificquot;
      />




  Six Feet Up, Inc. • http://www.sixfeetup.com             Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                           03.12.2008




                                       Zope 3 resources

                       <browser:resourceDirectory
                         name=quot;example-app-imagesquot;
                         directory=quot;imagesquot;
                         layer=quot;.interfaces.IThemeSpecificquot;
                         />

                       /++resource++example-app-images/foo.jpg



  Six Feet Up, Inc. • http://www.sixfeetup.com                   Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                           03.12.2008




                                                    The Future




  Six Feet Up, Inc. • http://www.sixfeetup.com                   Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                    03.12.2008




                                                    FIN




  Six Feet Up, Inc. • http://www.sixfeetup.com            Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                           03.12.2008




                                                    Questions?




  Six Feet Up, Inc. • http://www.sixfeetup.com                   Silicon Valley • Midwest
Getting Plone Ready for the Prom - Clayton Parker                                03.12.2008




                                                    Support

    http://plone.org/documentation
    https://weblion.psu.edu/trac/weblion/wiki/WebDevelopment
    http://plone.org/documentation/how-to/firefox-tools
    http://plone.org/documentation/tutorial/creating-plone-themes
    http://plone.org/documentation/tutorial/customizing-main-template-viewlets
    http://plone.org/documentation/tutorial/zpt
    Professional Plone Development Book
    http://www.packtpub.com/Professional-Plone-web-applications-CMS/book



  Six Feet Up, Inc. • http://www.sixfeetup.com                        Silicon Valley • Midwest

Weitere ähnliche Inhalte

Andere mochten auch

Genewro Emo
Genewro EmoGenewro Emo
Genewro Emo
wentati
 
ApresentaçãO Para DéCimo Primeiro Ano, Aula 10
ApresentaçãO Para DéCimo Primeiro Ano, Aula 10ApresentaçãO Para DéCimo Primeiro Ano, Aula 10
ApresentaçãO Para DéCimo Primeiro Ano, Aula 10
luisprista
 
Projecto Clube Do Xadrez Escola
Projecto Clube Do Xadrez  EscolaProjecto Clube Do Xadrez  Escola
Projecto Clube Do Xadrez Escola
isabelpinto
 
Hip Hop Slide4[1]
Hip Hop Slide4[1]Hip Hop Slide4[1]
Hip Hop Slide4[1]
guest867e06
 
Nicolas Gutierrez Presentacion, Propuesta Formal
Nicolas Gutierrez   Presentacion, Propuesta FormalNicolas Gutierrez   Presentacion, Propuesta Formal
Nicolas Gutierrez Presentacion, Propuesta Formal
Incolas
 
Lincoln Tigers
Lincoln TigersLincoln Tigers
Lincoln Tigers
Brandon22
 

Andere mochten auch (20)

LDAP and Active Directory Authentication in Plone
LDAP and Active Directory Authentication in PloneLDAP and Active Directory Authentication in Plone
LDAP and Active Directory Authentication in Plone
 
Zen and the Art of Python
Zen and the Art of PythonZen and the Art of Python
Zen and the Art of Python
 
graficas
graficasgraficas
graficas
 
Rodrick Stewart
Rodrick StewartRodrick Stewart
Rodrick Stewart
 
In Plano De Marketing 1221779188910665 9
In Plano De Marketing 1221779188910665 9In Plano De Marketing 1221779188910665 9
In Plano De Marketing 1221779188910665 9
 
GCSE Change
GCSE ChangeGCSE Change
GCSE Change
 
Patrones1b
Patrones1bPatrones1b
Patrones1b
 
Genewro Emo
Genewro EmoGenewro Emo
Genewro Emo
 
Dona Izabel
Dona IzabelDona Izabel
Dona Izabel
 
Dreams
DreamsDreams
Dreams
 
ApresentaçãO Para DéCimo Primeiro Ano, Aula 10
ApresentaçãO Para DéCimo Primeiro Ano, Aula 10ApresentaçãO Para DéCimo Primeiro Ano, Aula 10
ApresentaçãO Para DéCimo Primeiro Ano, Aula 10
 
Terapia Hiperealista
Terapia HiperealistaTerapia Hiperealista
Terapia Hiperealista
 
Projecto Clube Do Xadrez Escola
Projecto Clube Do Xadrez  EscolaProjecto Clube Do Xadrez  Escola
Projecto Clube Do Xadrez Escola
 
Ant Judíos Tomo I
Ant Judíos Tomo IAnt Judíos Tomo I
Ant Judíos Tomo I
 
Sosyal Agina Dusurmek
Sosyal Agina DusurmekSosyal Agina Dusurmek
Sosyal Agina Dusurmek
 
Llocs 3r Europa
Llocs 3r EuropaLlocs 3r Europa
Llocs 3r Europa
 
Hip Hop Slide4[1]
Hip Hop Slide4[1]Hip Hop Slide4[1]
Hip Hop Slide4[1]
 
Nicolas Gutierrez Presentacion, Propuesta Formal
Nicolas Gutierrez   Presentacion, Propuesta FormalNicolas Gutierrez   Presentacion, Propuesta Formal
Nicolas Gutierrez Presentacion, Propuesta Formal
 
Instructions To Authors
Instructions To AuthorsInstructions To Authors
Instructions To Authors
 
Lincoln Tigers
Lincoln TigersLincoln Tigers
Lincoln Tigers
 

Mehr von Clayton Parker

Pioneer a Strategic Change in Content Organization with Plone
Pioneer a Strategic Change in Content Organization with PlonePioneer a Strategic Change in Content Organization with Plone
Pioneer a Strategic Change in Content Organization with Plone
Clayton Parker
 

Mehr von Clayton Parker (17)

Customizing Your Shell With Dotfiles
Customizing Your Shell With DotfilesCustomizing Your Shell With Dotfiles
Customizing Your Shell With Dotfiles
 
Vim for Mere Mortals
Vim for Mere MortalsVim for Mere Mortals
Vim for Mere Mortals
 
Fuzzy Feelings for Fuzzy Matching
Fuzzy Feelings for Fuzzy MatchingFuzzy Feelings for Fuzzy Matching
Fuzzy Feelings for Fuzzy Matching
 
Exploring Code with Pry!
Exploring Code with Pry!Exploring Code with Pry!
Exploring Code with Pry!
 
So you think you can pdb?
So you think you can pdb?So you think you can pdb?
So you think you can pdb?
 
Managing Chaos: Merging 120 Sites into a single Plone Multisite Solution
Managing Chaos: Merging 120 Sites into a single Plone Multisite SolutionManaging Chaos: Merging 120 Sites into a single Plone Multisite Solution
Managing Chaos: Merging 120 Sites into a single Plone Multisite Solution
 
Current State of Python Packaging
Current State of Python PackagingCurrent State of Python Packaging
Current State of Python Packaging
 
Notre Dame Seamless Syndication with Lineage
Notre Dame Seamless Syndication with LineageNotre Dame Seamless Syndication with Lineage
Notre Dame Seamless Syndication with Lineage
 
Pioneer a Strategic Change in Content Organization with Plone
Pioneer a Strategic Change in Content Organization with PlonePioneer a Strategic Change in Content Organization with Plone
Pioneer a Strategic Change in Content Organization with Plone
 
Using Buildout, GenericSetup and a Policy Package to Rule the World
Using Buildout, GenericSetup and a Policy Package to Rule the WorldUsing Buildout, GenericSetup and a Policy Package to Rule the World
Using Buildout, GenericSetup and a Policy Package to Rule the World
 
Make Plone Search Act Like Google Using Solr
Make Plone Search Act Like Google Using SolrMake Plone Search Act Like Google Using Solr
Make Plone Search Act Like Google Using Solr
 
Buildout for the Future
Buildout for the FutureBuildout for the Future
Buildout for the Future
 
Laying Pipe with Transmogrifier
Laying Pipe with TransmogrifierLaying Pipe with Transmogrifier
Laying Pipe with Transmogrifier
 
Code with Style - PyOhio
Code with Style - PyOhioCode with Style - PyOhio
Code with Style - PyOhio
 
Code with style
Code with styleCode with style
Code with style
 
Using Buildout to Develop and Deploy Python Projects
Using Buildout to Develop and Deploy Python ProjectsUsing Buildout to Develop and Deploy Python Projects
Using Buildout to Develop and Deploy Python Projects
 
Generic Setup De-Mystified
Generic Setup De-MystifiedGeneric Setup De-Mystified
Generic Setup De-Mystified
 

Kürzlich hochgeladen

Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
panagenda
 
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
 
Harnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptx
Harnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptxHarnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptx
Harnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptx
FIDO Alliance
 

Kürzlich hochgeladen (20)

Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...
Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...
Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...
 
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
 
Top 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development CompaniesTop 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development Companies
 
The Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdf
The Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdfThe Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdf
The Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdf
 
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
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!
 
Design and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data ScienceDesign and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data Science
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
 
Overview of Hyperledger Foundation
Overview of Hyperledger FoundationOverview of Hyperledger Foundation
Overview of Hyperledger Foundation
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 Warsaw
 
TopCryptoSupers 12thReport OrionX May2024
TopCryptoSupers 12thReport OrionX May2024TopCryptoSupers 12thReport OrionX May2024
TopCryptoSupers 12thReport OrionX May2024
 
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdfSimplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
 
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
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
 
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The InsideCollecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
 
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...
 
Introduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptxIntroduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptx
 
Harnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptx
Harnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptxHarnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptx
Harnessing Passkeys in the Battle Against AI-Powered Cyber Threats.pptx
 
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfIntroduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
 

Getting Plone Ready For The Prom

  • 1. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Getting Plone Ready for the Prom Plone Symposium East 2008 Clayton Parker March 12, 2008 Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 2. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Who Am I? • Plone developer since 2003 • Lead Developer at Six Feet Up, Inc. • All around nice guy :) Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 3. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 What are we in for? • Approaches to skinning Plone • Tools used • Advanced techniques Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 4. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Where to start • Debug mode • $INSTANCE_HOME/bin/zopectl fg • $buildout/bin/instance fg • zope.conf • debug-mode on Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 5. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 More debug modes • portal_css • portal_javascripts • portal_kss Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 6. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Get to know Plone Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 7. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Get to know Plone Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 8. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Theories of Skinning • Light Skinning • use base_properties Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 9. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 base_properties title:string=Plone's color, font, logo and border defaults plone_skin:string=Plone Default logoName:string=logo.jpg fontFamily:string=quot;Lucida Grandequot;,Verdana, Lucida, Helvetica, Arial, sans-serif fontBaseSize:string=69% fontColor:string=Black fontSmallSize:string=90% backgroundColor:string=White linkColor:string=#436976 linkActiveColor:string=Red linkVisitedColor:string=Purple borderWidth:string=1px borderStyle:string=solid borderStyleAnnotations:string=solid Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 10. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 css.dtml? /* <dtml-with base_properties> (do not remove this :) */ /* <dtml-call quot;REQUEST.set('portal_url', portal_url())quot;> (not this either :) */ Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 11. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Example in the wild body { font: &dtml-fontBaseSize; <dtml-var fontFamily>; background-color: &dtml-backgroundColor;; color: &dtml-fontColor;; margin: 0; padding: 0; } table { font-size: 100%; } a{ color: &dtml-linkColor;; background-color: transparent; } img { pulled from border: none; base.css.dtml vertical-align: middle; } p{ margin: 0 0 0.75em 0; line-height: 1.5em; } Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 12. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Building on the base • ploneCustom.css • override plone styles Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 13. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Going all the way • Clean the slate • Leave just authoring.css Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 14. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 TTW vs FS Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 15. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Now I’m convinced. • DIYPloneStyle • ZopeSkel • GenericSetup Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 16. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Resource registries • portal_css • portal_javascripts Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 17. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Resource registries Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 18. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Advanced techniques Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 19. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Viewlets • New to Plone 3 • More control over the main_template Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 20. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Using @@manage-viewlets Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 21. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Using @@manage-viewlets Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 22. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Using @@manage-viewlets Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 23. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Layers from plone.theme.interfaces import IDefaultPloneLayer class IThemeSpecific(IDefaultPloneLayer): quot;quot;quot;Marker interface that defines a Zope 3 browser layer. If you need to register a viewlet only for the quot;examplequot; theme, this interface must be its layer (in theme/viewlets/configure.zcml). quot;quot;quot; Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 24. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Layers <interface interface=quot;.interfaces.IThemeSpecificquot; type=quot;zope.publisher.interfaces.browser.IBrowserSkinTypequot; name=quot;examplequot; /> Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 25. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Moving viewlets <browser:viewlet name=quot;plone.abovecontenttitle.documentactionsquot; manager=quot;plone.app.layout.viewlets.interfaces.IAboveContentTitlequot; class=quot;plone.app.layout.viewlets.content.DocumentActionsViewletquot; permission=quot;zope2.Viewquot; layer=quot;.interfaces.IThemeSpecificquot; /> Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 26. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Overriding viewlets <browser:viewlet name=quot;plone.footerquot; for=quot;*quot; manager=quot;plone.app.layout.viewlets.interfaces.IPortalFooterquot; template=quot;mytheme_footer.ptquot; permission=quot;zope.Publicquot; layer= quot;.interfaces.IThemeSpecificquot; /> Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 27. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 z3c.jbot eggs = z3c.jbot zcml = z3c.jbot-meta <browser:templateOverrides directory=quot;templatesquot; /> templates/plone.app.layout.viewlets.footer.pt Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 28. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Overriding portlets <plone:portletRenderer portlet=quot;plone.app.portlets.portlets.news.INewsPortletquot; template=quot;mytheme_news.ptquot; layer=quot;.interfaces.IThemeSpecificquot; /> Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 29. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Zope 3 resources <browser:resourceDirectory name=quot;example-app-imagesquot; directory=quot;imagesquot; layer=quot;.interfaces.IThemeSpecificquot; /> /++resource++example-app-images/foo.jpg Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 30. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 The Future Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 31. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 FIN Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 32. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Questions? Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest
  • 33. Getting Plone Ready for the Prom - Clayton Parker 03.12.2008 Support http://plone.org/documentation https://weblion.psu.edu/trac/weblion/wiki/WebDevelopment http://plone.org/documentation/how-to/firefox-tools http://plone.org/documentation/tutorial/creating-plone-themes http://plone.org/documentation/tutorial/customizing-main-template-viewlets http://plone.org/documentation/tutorial/zpt Professional Plone Development Book http://www.packtpub.com/Professional-Plone-web-applications-CMS/book Six Feet Up, Inc. • http://www.sixfeetup.com Silicon Valley • Midwest