Table of Contents
- Foreword
- Preface
- Intended Audience
- Requirements
- How to Read This Book
- Overview
- Other Resources
- Typographic Conventions
- We'd Like to Hear from You
- Open Publication License
- Acknowledgments
- Chapter 1: Introduction
- A First Example
- The Main Features of Mason
- Components: Modular Design Elements
- Object-Style Component Inheritance
- Intelligent Caching Mechanisms
- Integration with Apache and mod_perl
- Alternatives to Mason
- Philosophy
- Getting Started with Mason
- Chapter 2: Components
- Mason from 10,000 Feet
- Core Concepts
- Basic Component Syntax
- Substitution Tags: <% %>
- Embedded Perl: % Lines and <%perl> Blocks
- Calling Other Components: <& &> Tags
- Other Named Blocks
- Escaping a Newline
- Component Arguments
- <%args> Block Revisited
- %ARGS
- %ARGS Versus @_
- Argument Examples
- Arguments via Component Calls
- Arguments via HTTP Requests
- Component Return Values
- Special Globals
- Sample Component
- Chapter 3: Special Components: Dhandlers and Autohandlers
- Chapter 4: APIs
- Request Class and Object API
- Constructor Parameters
- Calling Other Components
- Aborting the Flow of Execution
- The Wrapping Chain
- Dhandler-Related Methods
- Miscellaneous Methods
- Introspection
- Buffer-Related Methods
- Caching
- Subrequests
- Methods Available Only When Using ApacheHandler
- Methods Available When Using ApacheHandler or CGIHandler
- Getting in Close with Buffers
- Component Object API
- Buffers
- Chapter 5: Advanced Features
- Subcomponents
- Creating Components on the Fly
- Sharing Data Among Component Sections
- Methods and Attributes
- Methods
- Using Methods for Titles and Headers
- Methods with Dynamic Content
- Attributes
- Top-Down Versus Bottom-Up Inheritance
- Calling Components with Content Blocks
- Advanced Inheritance
- Subrequests
- Chapter 6: The Lexer, Compiler, Resolver, and Interpreter Objects
- Chapter 7: Using Mason with mod_perl
- Configuring Mason
- Document Root Versus the Component Root
- Not OK
- $r
- ApacheHandler Parameters
- To Autoflush or Not to Autoflush
- Generating Something Besides HTML
- Apache::Status and Mason
- Chapter 8: Building a Mason Site
- Functionality
- Directory Layout
- File Extensions
- Apache Configuration
- The Components
- Components with Access Controls
- All Done
- Further Directions
- Chapter 9: Mason and CGI
- CGI-Appropriate Situations
- CGI-Inappropriate Situations
- Creating a CGI-Based Site in Mason
- Using Mason Templates Inside Regular CGI Scripts
- Differences Between Mason Under CGI and mod_perl
- Chapter 10: Scalable Design
- Modules Versus Components
- Components as Independent Units
- Component Layout
- File Naming and Directory Layout
- Random Advice
- Chapter 11: Recipes
- Sessions
- Without Touching httpd.conf
- Predeclaring the Global via an httpd.conf File
- Predeclaring the Global via a handler.pl Script
- Using Cache::Cache for Sessions
- Putting the Session ID in the URL
- Making Use of Autoflush
- User Authentication and Authorization
- Co-Branding Color Schemes
- Developer Environments
- Using Mason Outside of Dynamic Web Sites
- Chapter 12: Custom Mason Subclasses
- Class::Container as a Superclass
- Syntax: Your Very Own Lexer
- Output: Compiling to a Different Output
- Storage: Replacing the Resolver
- Request: A Request Object with a Built-in Session
- Argument Munging: ApacheHandler
- More Reader Exercises
- Appendix A: The Mason API
- Interpreter
- Request
- Object Properties
- Altering the Request Flow
- Caching
- Introspection
- Content and Output
- Fetching/Running Components
- Subrequests
- Component
- Resolver
- ApacheHandler
- CGIHandler
- Compiler
- Lexer
- Appendix B: Object Constructor Parameters
- HTML::Mason::Interp
- HTML::Mason::Request
- HTML::Mason::Resolver::File
- HTML::Mason::ApacheHandler
- HTML::Mason::Compiler
- HTML::Mason::Component
- HTML::Mason::Buffer
- HTML::Mason::CGIHandler
- HTML::Mason::Lexer
- Appendix C: Text Editors That Understand Mason
- Appendix D: Content Management with Bricolage
- Installing Bricolage
- Elements: the Building Blocks of Content
- Content Editing
- Templates
- Where to Learn More
- Glossary
- Colophon
- Copyright
These HTML pages were created by running this script against the pseudo-POD source.