[TYPO3-english] comments => latest comments ?
StephenBungert
stephenbungert at yahoo.de
Fri May 29 09:32:46 CEST 2009
Well you know that tt_news_ is always there, then you could try using the
stdWrap property substring(8). I think 8 is right here, I'm sure the
counting of chracters starts at zero.
Don't know if that will work but maybe you can try it.
daniel huf-2 wrote:
>
> This is the closest I can get, do have another trick to separate the
> "tt_news_120" into 120 ?
>
> the link I get is &tx_ttnews[tt_news]=tt_news_120
>
> hmm
> thanks
> Daniel
>
> CONSTANTS
>
> lib.page.comments.latest.limit = 10
> lib.page.comments.latest.pidInList = 73
> lib.page.comments.latest.detailPid = 65
>
> SETUP
>
> lib.page.comments.latest = COA
> lib.page.comments.latest.wrap = <div class="comments">|</div>
> lib.page.comments.latest{
>
> 20 = CONTENT
> 20 {
> table = tx_comments_comments
> select {
> orderBy = tstamp DESC
> pidInList = {$lib.page.comments.latest.pidInList}
> where = deleted = 0 and hidden = 0 and approved = 1
> max = {$lib.page.comments.latest.limit}
> }
>
> renderObj = COA
> renderObj.wrap = <div class="comment">|</div>
> renderObj{
> 5 = COA
> 5 {
> 10 = TEXT
> 10.field = firstname
> 10.required = 1
> 10.wrap = |
>
> 20 = TEXT
> 20.field = lastname
> 20.required = 1
> 20.wrap = |
> stdWrap.typolink.parameter.field = email
> stdWrap.typolink.ATagParams = class="commentemail"
>
> }
>
> 20 = TEXT
> 20 {
> field = content
> wrap = <p>commentaire: |</p>
> typolink.parameter = {$lib.page.comments.latest.detailPid}
> typolink.additionalParams.dataWrap =
> &tx_ttnews[tt_news]={field:external_ref}
> typolink.useCacheHash = 1
> }
> 30 = TEXT
> 30.field = external_ref
> 30.split {
> token.char = 95
> returnKey = 2
> }
> }
> }
> }
>
> Daniel Huf wrote:
>> I'm trying to get the latest comments from the folder where they are
>> located.
>>
>> That for I wrote this TS... but I'm not able to create the typolink to
>> link back to the news where the comment belongs... do you have an input.
>>
>> thanks
>> Daniel
>>
>> CONSTANTS
>>
>> lib.page.comments.latest.limit = 10
>> lib.page.comments.latest.pidInList = 73
>>
>> SETUP
>>
>> lib.page.comments.latest = COA
>> lib.page.comments.latest.wrap = <div class="comments">|</div>
>> lib.page.comments.latest{
>>
>> 20 = CONTENT
>> 20 {
>> table = tx_comments_comments
>> select {
>> orderBy = tstamp DESC
>> pidInList = {$lib.page.comments.latest.pidInList}
>> where = deleted = 0 and hidden = 0 and approved = 1
>> max = {$lib.page.comments.latest.limit}
>> }
>>
>> renderObj = COA
>> renderObj.wrap = <div class="comment">|</div>
>> renderObj{
>> 5 = COA
>> 5 {
>> 10 = TEXT
>> 10.field = firstname
>> 10.required = 1
>> 10.wrap = |
>>
>> 20 = TEXT
>> 20.field = lastname
>> 20.required = 1
>> 20.wrap = |
>> stdWrap.typolink.parameter.field = email
>> stdWrap.typolink.ATagParams = class="commentemail"
>>
>> }
>>
>> 20 = TEXT
>> 20 {
>> field = content
>> wrap = <p>commentaire: |</p>
>> }
>> 30 = TEXT
>> 30.field = external_ref
>> 30.split {
>> token.char = 95
>> returnKey = 2
>> }
>> }
>> }
>> }
> _______________________________________________
> TYPO3-english mailing list
> TYPO3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>
>
-----
--
Stephen Bungert
--
View this message in context: http://www.nabble.com/-TYPO3-english---comments-%3D%3E-latest-comments---tp23764658p23775571.html
Sent from the TYPO3 English mailing list archive at Nabble.com.
More information about the TYPO3-english
mailing list