[TYPO3-english] tt_news TypoScript

Lamb, Brian blamb at jcvi.org
Fri Oct 30 15:30:22 CET 2009


I wanted to bring this topic up again. I added the TypoScript below to my template. I assume that the UIDs are the numbers that pop up when I hover over the tt_news item in the backend. However, using only the TypoScript below, the title is not displayed (I am using the second method). Does anyone have any advice as to what I'm doing wrong?

Thanks, 

Brian Lamb

 

Message: 2
Date: Mon, 21 Sep 2009 12:10:23 +0000 (UTC)
From: Michael Miousse <mmiousse at infoglobe.ca>
Subject: Re: [TYPO3-english] tt_news TypoScript
To: typo3-english at lists.netfielders.de
Message-ID:
        <mailman.1.1253535023.13629.typo3-english at lists.netfielders.de>
Content-Type: text/plain; charset=UTF-8

Le Fri, 18 Sep 2009 08:49:26 -0400, Lamb, Brian a ?crit?:

Yes you can

There is 2 different way  of doing what you wish to do

the first one is using only typoscript objects to achive it something like this:

lib.news1 < plugin.tt_news
lib.news1{
        code>
        code = LIST
        pid_list = 12
}
lib.news2 < plugin.tt_news
lib.news2{
        code>
        code = LIST
        pid_list = 13
}

and then you map your 2 ts object into your template

the second one is by using tt_news plugins

you start by creating 2 tt_news plugins  and you keep their uids

then you create 2 distinct ts object  of type RECORDS

lib.news1 = RECORDS
lib.news1{
        source = 12 // this is the uid of one of your 2 plugins you created
        tables = tt_content
        conf.tt_content < plugin.tt_news
        conf.tt_content{
                displaySingle.title_stdWrap.wrap = <div>this is My first Plugin</div>|
        }
}

lib.news2 = RECORDS
lib.news2{
        source = 13 // this is the uid of one the other plugin you created
        tables = tt_content
        conf.tt_content < plugin.tt_news
        conf.tt_content{
                displaySingle.title_stdWrap.wrap = <div>this is My second Plugin</div>|
        }
}


and then you map your 2 ts object (lib.news1,lib.news2) into your template using templavoila

the second methode is usefull in case you need edimaster to change your plugin. It uses the plugin you created instead ts only

 

> Greetings all,
>
> I posed this question recently but I think it may have gotten lost in
> the shuffle because my reply changed the subject. Essentially, I want to
> associate two different tt_news elements on the same page with different
> TypoScripts. I render these objects with TemplaVoila. Any thoughts on
> how to do that?
>
> Thanks,
>
> Brian Lamb
>
>
> Date: Wed, 16 Sep 2009 10:06:02 -0400 From: Dan Osipov
> <dosipov at phillyburbs.com> Subject: Re: [TYPO3-english] tt_news
> TypoScript To: typo3-english at lists.netfielders.de Message-ID:
>         <mailman.1.1253109962.24179.typo3-english at lists.netfielders.de>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> If you render the objects through TS, then you just need to modify the
> individual object code:
>
> page.32 < plugin.tt_news
> page.32 {
>     displayLatest {
>       title_stdWrap.crop = 140 | ... | 1
>     }
> }
> page.33 < plugin.tt_news
> page.33 {
>     displayLatest {
>       title_stdWrap.crop = 20 | ... | 1
>     }
> }
>
> Dan Osipov
> Calkins Media
> http://danosipov.com/blog/ <https://owa.jcvi.org/exchweb/bin/redir.asp?URL=http://danosipov.com/blog/> 
> <https://owa.jcvi.org/exchweb/bin/redir.asp?URL=http://danosipov.com/blog/ <https://owa.jcvi.org/exchweb/bin/redir.asp?URL=https://owa.jcvi.org/exchweb/bin/redir.asp?URL=http://danosipov.com/blog/> >
>
> Lamb, Brian wrote:
>> Greetings all,
>>
>> Is it possible to attribute different TypoScript descriptions to
>> different tt_news records on the same page? For example, I have the
>> following TypoScript on a page:
>>
>> plugin.tt_news {
>>   displayLatest {
>>     title_stdWrap.crop = 140 | ... | 1
>>   }
>> }
>>
>> Which applies to both instances of tt_news on the same page. However, I
>> would like to have one tt_news object use this, and another change the
>> crop information to be a bit smaller. Is this possible? If so, how?
>>
>> Thanks,
>>
>> Brian Lamb



------------------------------



More information about the TYPO3-english mailing list