[TYPO3-ttnews] news/blog with commenting system
Erik Svendsen
erik at linnearad.no
Tue Jul 8 17:49:33 CEST 2008
Hello Michael,
http://support.typo3.org/projects/tt-news/m/typo3-ttnews-list-and-single-on-1-page-show-latest-item-in-single-when-opening-328422/p/58/
I remember I had some small problem, but to help you have I copied in the
code which are working on one site. NB! I'm using TV, and lib.tsContent are
refering to a simple FCE. It's possible I'm suing more code than neccessary,
but I don't see this as a big problem.
<--code-->
plugin.tt_news._LOCAL_LANG.default.noNewsIdMsg =
plugin.tt_news._LOCAL_LANG.no.noNewsIdMsg =
plugin.tt_news.excludeAlreadyDisplayedNews = 0
plugin.tt_news.singlePid = 234
temp.singleNews >
temp.singleNews < plugin.tt_news
temp.singleNews {
code >
code = SINGLE
pid_list >
pid_list = 263
singlePid = 234
catImageMode = 0
catTextMode = 0
displaySingle.image {
}
}
tmp.pagecontent < temp.singleNews
temp.singleNews >
temp.singleNews = COA
temp.singleNews {
10 = CONTENT
10.table = tt_news
10.select {
pidInList = 263
orderBy = datetime desc
max = 1
}
10.stdWrap.if.isFalse.data = GPvar:tx_ttnews|tt_news
20 < tmp.pagecontent
}
temp.listNews >
temp.listNews < plugin.tt_news
temp.listNews {
code >
code = LIST
pid_list >
pid_list = 263
allowCaching = 1
catImageMode = 0
catTextMode = 0
limit = 10
singlePid = 234
#backPid = 234
excludeAlreadyDisplayedNews = 0
displayList.subheader_stdWrap {
ifEmpty.field = bodytext
crop = 200 | ... | 1
}
displayList {
linkTitleField = title
linkTitleField.wrap = |
}
displayList.image {
file.maxW = 110
file.maxH = 110
}
}
plugin.tt_news.code >
plugin.tt_news.code = LIST
config.index_enable = 0
[globalVar = GP:tx_ttnews|tt_news > 0]
plugin.tt_news.code = SINGLE
config.index_enable = 1
[global]
#temp.singleNews >
#temp.singleNews < plugin.tt_news
lib.tsContent >
lib.tsContent = COA
lib.tsContent {
10 >
10 < temp.singleNews
10.wrap = <div class="mainContentLeft"> | </div>
20 = HTML
20.value = <hr class="clearer" /><h1>Tidligere sesongens fisk </h1>
30 >
30 < temp.listNews
30.wrap = <div class="mainContentRight"> | </div>
}
<-- code end -->
> Hi again,
>
> Thanks for the hints. I followed the example on page 62 (default news
> id) but still can't get it to work. I have made an external template
> (inserted a new template record) on the "SINGLE" page and included it
> in the setup template. For starters I want to remove the "no news
> id..." with the following ts-code (taken from the example):
>
> plugin.tt_news._LOCAL_LANG.default.noNewsIdMsg =
>
> but can't get it to work, what am I doing wrong?
>
>> Search this list or the english list. I think I have given an answer
>> at this
>> before (it's on this list). Single and latest/list on same page.
> It appears that the search function is unavailable, can you give a
> link to your old answer?
> (http://support.typo3.org/other-views/search-newsgroups/)
>
> Kind Regards / Med venlig hilsen
> Michael Lindholm Nielsen
WBR,
Erik Svendsen
www.linnearad.no
More information about the TYPO3-project-tt-news
mailing list