Return to Snippet

Revision: 24634
at March 6, 2010 01:53 by nick108


Initial Code
# Configuring the Auto-Parser for main template:
plugin.tx_automaketemplate_pi1 {
    # Read the template file:
  content = FILE

  content.file = fileadmin/templates/main-template.html

    # Here we define which elements in the HTML that 
    # should be wrapped in subpart-comments:
  elements {
    BODY.all = 1
    BODY.all.subpartMarker = DOCUMENT_BODY

    HEAD.all = 1
    HEAD.all.subpartMarker = DOCUMENT_HEADER
    HEAD.rmTagSections = title

    DIV.all = 1
    SPAN.all = 1
  }

    # Prefix all relative paths with this value:
  relPathPrefix = fileadmin/templates/
}

# Main TEMPLATE cObject for the BODY
temp.mainTemplate = TEMPLATE
temp.mainTemplate {
    # Feeding the content from the Auto-parser to the TEMPLATE cObject:
  template =< plugin.tx_automaketemplate_pi1
    # Select only the content between the <body>-tags
  workOnSubpart = DOCUMENT_BODY

    # Substitute the ###theme### subpart with a theme image:
  subparts.theme < temp.theme

    # Substitute the ###topmenu### subpart with dynamic menu:
  subparts.topmenu < temp.menu

    # Substitute the ###content### subpart
  subparts.content < styles.content.get

    # Substitute the ###language### subpart
  subparts.language < temp.language

    # Substitute the ###search### subpart with the search form:
  subparts.search < temp.search

    # Substitute the ###news### subpart with the news teasers:
  subparts.news < styles.content.getRight
}

# Main TEMPLATE cObject for the HEAD
temp.headTemplate = TEMPLATE
temp.headTemplate {
    # Feeding the content from the Auto-parser to the TEMPLATE cObject:
  template =< plugin.tx_automaketemplate_pi1
    # Select only the content between the <head>-tags

  workOnSubpart = DOCUMENT_HEADER

}

# Default PAGE object:
page = PAGE
page.typeNum = 0

# Copying the content from TEMPLATE for <body>-section:
page.10 < temp.mainTemplate

# Copying the content from TEMPLATE for <head>-section:
page.headerData.10  < temp.headTemplate

Initial URL


Initial Description


Initial Title
Auto-Parser Configuration

Initial Tags


Initial Language
TYPO3