panels 3 the power of chaos magic
play

Panels 3: The Power of Chaos Magic Matt Cheney November 14th, - PowerPoint PPT Presentation

Panels 3: The Power of Chaos Magic Matt Cheney November 14th, 2009 Drupalcamp Austin 2009 Panels is our Best Hope Marshall Content Drag & Drop Layout Configurable in the UI Views 2 + CCK Integration Killer API


  1. Panels 3: The Power of Chaos Magic Matt Cheney November 14th, 2009 Drupalcamp Austin 2009

  2. Panels is our Best Hope • Marshall Content • Drag & Drop Layout • Configurable in the UI • Views 2 + CCK Integration • Killer API • Exportable Elements “what do you want in your CMS?”

  3. A Little History.... Panels 1 (5.x)

  4. A Little History.... Panels 2 (5.x) Panels 2 (6.x) the long road...

  5. A Little History.... panels 3.0 released 9.19.09

  6. What Does it Do?

  7. What Does it Do?

  8. The Panels Paradigm Every Page is a Panel No Blocks

  9. A Tour of the Amazing

  10. Node Overrides + CCK • Allows Panels to Power the Node Display • Harness the Power of CCK (and why this rocks in CCK 3)

  11. Node Overrides + CCK showcase

  12. Views 2 Integration

  13. Views 2 Integration showcase

  14. Styles + skinr.module

  15. panels-pane.tpl.php Variables available: * - $pane->type: the content type inside this pane * - $pane->subtype: The subtype, if applicable. status : * - $title: The title of the content http://drupal.org/node/583172 * - $content: The actual content (now in Panels 3.2!) * - $links: Any links associated with the content * - $more: An optional 'more' link (destination only) * - $admin_links: Administrative links * - $feeds: Any feed associated with the content * - $display: The complete panels display object Why This Matters? <div class="panel-pane panel-pane-<?php print $pane->type; ?> "> or for the really cool kids... <div class=”panel-pane panel-position-<?php print $pane->position;?> panel-region-<?php print $pane->panel;?> panel-region-<?php print $pane->did;?>-<?php print $pane- >panel;?> panel-type-<?php print $pane->type;?> panel-display-<?php print $pane- >did;?> panel-pane-<?php print $pane->pid; ?> ">

  16. Caching + Performance If we are anonymous, we don’t (usually) care.... If we are logged in, we pay about 5%... (but we get pane caching for free)

  17. Panels, Ctools, Features http://drupal.org/node/532256

  18. panels_scheduler.module • Add Date Field to Panel Node Content Type • Create Custom Callback to Find Current Page • return node_view($node)! status : http://drupal.org/project/panels_scheduler

  19. panels_scheduler.module enter the demo

  20. og_panels.module • OG + Panels = Great • A model for how to have users manage groups status : http://drupal.org/project/og_panels

  21. og_panels.module enter the demo

  22. total_control.module • Views 2 + Panels 3 = Admin 5000 • Flexible + Customizable • The Content Admin Solution status : http://drupal.org/project/total_control

  23. total_control.module enter the demo

  24. Panels and Chaos Tools Chaos Tools a shared suite of APIs and tools to allow for wizardly development drupal.org/project/ctools Panels a system of layout and pane control to create your website drupal.org/project/panels

  25. The Panels/CTools API /** * Implementation of hook_ctools_plugin_directory() to let * the system know we implement task and task_handler plugins. */ function module_name_ctools_plugin_directory($module, $plugin) { return 'plugins/' . $plugin; } module/plugins/content_types/ module/plugins/layouts/ module/plugins/contexts/ module/plugins/arguments/ module/plugins/tasks/

  26. Extending Panels: Layouts hook_panels_layouts() A recipe for a custom panel layout... layout_name.css + layout_name.inc + layout_name.tpl.php + layout_name.png

  27. Extending Panels: Layouts enter the code

  28. Extending Panels: Panes hook_ctools_content_types() A recipe for a custom panel pane... module_custompane_ctools_content_types() + module_custompane_content_type_render() + module_custompane_content_type_edit_form() + module_custompane_content_type_edit_form_submit() more information in the ctools_plugin_example module

  29. Extending Panels: Panes enter the code

  30. Content Creation in Panels • Panels “Content Types”: Not Just for CCK! • Create Content: Images/Feeds/Embeds status : http://drupal.org/node/451928

  31. Content Creation in Panels enter the demo

  32. The Future Is Now released

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend