[Typo3] Other colpos value than '0' using TemplaVoila

tapio tapio.markula at dnainternet.net
Tue Jun 21 11:08:52 CEST 2005


> Normally if you create a content element using the TV page module it 
> will get inserted into the "Normal" column
> of the traditional Page module.
> You can set a different target colPos using TSConfig but just on a per 
> Page level ... you can't define that content
> Elements which you put into your "Left Shared Content" TV column should 
> end up in the "Left" MTB column and
> "Right Shared Content" TV column => "Right" MTB Column ...
> 
> that's simply not possible ...

Well - this IS possible just by setting different colpos value using
the SELECT-menu, which is available, when you modify the content.
Needs just a little information for the user and shared content works
as I have intended!

When you use MTB  and select for example
the column 'LEFT' Typo3 puts the value to the SELECT-menu automatic
as '1'.

But if you use MTB Typo3 put always the value automatic as '0' and the
user must always change it if he want different value.
NOT very difficult for the user - needs just a little intstruction to 
change the value.

THIS is simple way to mix ideas of TV and MTB. Now all shared content 
can be put into one page, for example pid=884 for the shared contents. 
Columns of TV works also as if colums of MTB!
The shared content page just needs at least own TO and sometimes also 
(but not necessary) different DS.

The only disadvantage is that those DS and TO are available also for
other pages even if they are intended for ONLY one page - or is it 
possible to hide them fron non-admin users?

for other pages

  lib.normalcontentshared  = CONTENT
  lib.normalcontentshared {
      select {
       pidInList = 384
       where = colpos=0
       andWhere = deleted=0
       andWhere = hidden=0
      }
     table = tt_content
  }

  lib.bordercontentshared  = CONTENT
  lib.bordercontentshared {
      select {
        pidInList = 384
        where = colpos=3
       andWhere = deleted=0
       andWhere = hidden=0
      }
      table = tt_content
  }

and this DS
<field_content2 type="array">
       <tx_templavoila type="array">
         <title>Sivun yhteinen sisältö (Shared contents) 	</title>
          <description>Sivun yhteinen sisältö (Shared 
contents).</description>
           <sample_data type="array">
                <numIndex index="0">Lorem ipsum.</numIndex>
             </sample_data>
           <eType>TypoScriptObject</eType>
          <tags>table:outer,td:inner,div:inner,p,h1,h2,h3,h4,h5</tags>
         <TypoScriptObjPath>lib.normalcontentshared</TypoScriptObjPath>
         </tx_templavoila>
        </field_content2>


        <field_footer type="array">
        <tx_templavoila type="array">
        <title>Sivun lopputeksti (Footer)</title>
       <description>Sivun lopputeksti (Footer).</description>
       <sample_data type="array">
            <numIndex index="3">Lorem ipsum.</numIndex>
       </sample_data>
       <eType>TypoScriptObject</eType> 
<tags>table:outer,td:inner,div:inner,p,h1,h2,h3,h4,h5</tags> 
          <TypoScriptObjPath>lib.bordercontentshared</TypoScriptObjPath>
        </tx_templavoila>
        </field_footer>

> I would know a solution with which it would be possible to use directly 
> the content-elements of a TV column as kind
> of static/shared content ...

Not necessary - mixing principles of TV and MTB is enough.
> 
> But that would require either "advanced" TS (have to thinker myself) 
> .... or a User-PHP-method.

Presumably too complex.



More information about the TYPO3-english mailing list