[TYPO3-UG Spain] Saludos y dudas de TS

Christian Bieber christian.bieber at dkd.de
Mon Feb 14 10:17:38 CET 2011


Hola

yo tengo un ejemplo fácil para utilizar automake template. esto funciona mucha veces.


plugin.tx_automaketemplate_pi1 {
    content = FILE
    content.file = fileadmin/plantillas/curso/ejemplo.html

    elements {
        BODY.all = 1
        BODY.all.subpartMarker = DOCUMENT_BODY
        HEAD.all = 1
        HEAD.all.subpartMarker = DOCUMENT_HEADER
        HEAD.rmTagSections = title
        DIV.all = 1
    }
    relPathPrefix = fileadmin/plantillas/curso/



pagina = PAGE
pagina {

  typeNum = 0

   10 = TEMPLATE
   10 {
        template =< plugin.tx_automaketemplate_pi1

        workOnSubpart = DOCUMENT_BODY
        subparts{    
        navegacion < temp.navegacion
        subnavegacion < temp.subnavegacion
        contenido < styles.content.get
        piedepagina < temp.piedepagina
        banner < temp.banner
        }
    }

}
En tus ejemplo me falta la asignación de los  "subparts".




Para quitar los comentarios en el código escribes siguiente código en la plantilla 

config.disablePrefixComment = 1 



Para utilizar TV, yo tengo dos cuestiones:

Es el codigo html valido?
Tiene el codigo html los tags "id"?


Normalmente los dos puntos son los problemos.


Perdon para mi espanol. 


Saludo
Christian Bieber

-----
Certified TYPO3 Integrator
mail at christian-bieber.de


Am 14.02.2011 um 09:44 schrieb Giuseppe Luigi Punzi:

> Si claro,
> 
> De hecho en 4.5.0 viene instalada por defecto si no me equivoco
> 
> El 14/02/2011 9:40, Marco Antonio Blanco escribió:
>> Hola Giuseppe. Perdona una pregunta tan básica, pero es por descartar motivos: ¿tienes instalada la extensión "automaketemplate"? Un saludo.
>> 
>> Según Giuseppe Luigi Punzi <glpunzi at lordzealon.com>:
>> 
>>> Hola a todos,
>>> 
>>> Ni me acordaba que estaba registrado en esta lista, y mis últimas dudas
>>> las he posteado en la lista inglesa :P
>>> 
>>> En el pasado estuve preguntando dudas por aquí, ya que Typo3 me gustó
>>> mucho, pero no tuve tiempo para dedicarle. Ahora, se me han presentado
>>> dos proyectillos webs que contengan blog, noticias, foros etc.. y quiero
>>> aprovechar para hacerlo con Typo3 y acostumbrarme a este CMF.
>>> 
>>> Intentando aprenderlo, y puesto TV me ha dado problemas porque no me
>>> aparecen los TAGs para poder hacer el mapping, y debido que mucha gente
>>> en el pasado me recomendó que es mejor construir las plantillas con TS,
>>> pues me he decidido a mriarme el tuto de modern template building.
>>> 
>>> El tema es, que en vez de hacerlo con la plantillla del tutorial, pues
>>> lo estoy haciendo con otra que descargué de oswd, en especial, ésta:
>>> http://www.oswd.org/design/preview/id/3699
>>> 
>>> Resulta, que estoy haciendo todos los pasos que dice el tutorial, y
>>> estoy en la parte donde construye el menu, y tengo el Setup del template
>>> de la siguiente manera:
>>> # Configuring the Auto-Parser for main template:
>>> plugin.tx_automaketemplate_pi1 {
>>>    # Read the template file:
>>>  content = FILE
>>>  content.file = fileadmin/templates/RedTie/index.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
>>>  }
>>>    # Prefix all relative paths with this value:
>>>  relPathPrefix = fileadmin/templates/RedTie/
>>> }
>>> 
>>> # Menu 1 cObject
>>> temp.menu_1 = HMENU
>>>  # First level menu-object, textual
>>> temp.menu_1.1 = TMENU
>>> temp.menu_1.1 {
>>>    # Propiedades del estado Normal
>>>  NO.allWrap = <div id="menu"> | </div>
>>>    # Enable active state and set properties:
>>> }
>>> 
>>>  # Objeto de menú de segundo nivel, textual
>>> temp.menu_1.2 = TMENU
>>> temp.menu_1.2 {
>>>    # Propiedades del estado normal:
>>>  NO.allWrap = <div id="submenu"> | </div>
>>>    # Activar el estado activo y definir propiedades:
>>> }
>>> 
>>> 
>>> 
>>> # 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 ###menu_1### subpart with some example content:
>>>  subparts.menu_1 < temp.menu_1
>>> 
>>>  subparts.content = TEXT
>>>  subparts.content.value = HELLO WORLD - CONTENT
>>> }
>>> # 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
>>> 
>>> El tema es, que me está ignorando. Es decir...en el código de la página
>>> generada, no me aparece las marcas que teóricamente tendría que hacer la
>>> ext del parser (las de <--- ### document body ### ---> etc..
>>> Y por otro lado, la página me sale tal cual se vé la plantilla de
>>> ejemplo, con sus datos y todos, vamos, que no la toca, quitando alguna
>>> referencia a las CSS en typo3tmp:
>>> http://www.lordzealon.com/t3/index.php?id=1
>>> 
>>> Alguna sugerencia? Me encuentro estancado en esta tontería.
>>> 
>>> Typo3 4.5.0
>>> 
>>> Un saludo y muchas gracias.
>>> _______________________________________________
>>> TYPO3-UG-Spain mailing list
>>> TYPO3-UG-Spain at lists.typo3.org
>>> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-ug-spain
>> 
>> 
>> 
> 
> _______________________________________________
> TYPO3-UG-Spain mailing list
> TYPO3-UG-Spain at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-ug-spain



More information about the TYPO3-UG-Spain mailing list