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

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Kürzlich hochgeladen (20)

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 

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