Thanks Joey,

You helped me make my TS quite a bit neater and shorter.

The only thing left now is a problem with a normal TS condition, about
which I started a different thread (glovalVar Condition problem).

I even managed to get rid of the half container for the entire content
area (which was closed in my html template until now). The reason it was
a half one was that I wanted to wrap three different subparts with it. I
know combined these into a COA and put the typosearch tags around the
middle one instead of in the html template.

Only one thing about your original suggestion:
G1G-2 is useless, as the values -2 and -1 for fe_group are used
stand-alone only. If you select either one in the backend, all other
values are removed.

---

Current TS:

temp.PageAccess = TEXT
temp.PageAccess.value = <div class="publicpage">|</div>

temp.MainContentWrap = CASE
temp.MainContentWrap {
        key {
                field = fe_group
                split {
                        token = ,
                        cObjNum = 1
                        1.current = 1
                        1.wrap = G|
                        }
                }
        default = TEXT
        default.value = <div class="public">|</div>
        G1 = TEXT
        G1.value = <div
class="membersonlytext">{$text.contentmembersonly}</div><div
class="membersonly">|</div>
        G-2 < .G1
        G1G2 < .G1
        G2G1 < .G1
        G2 = TEXT
        G2.value = <div class="ctonlytext">Coordination Team Only</div><div
class="ctonly">|</div>
}

# Members-Only Page

[globalVar = TSFE:page|fe_group = -2,TSFE:page|fe_group = 1] &&
[usergroup = 1,2]
temp.PageAccess = TEXT
temp.PageAccess.value = <div
class="membersonlytext">{$text.pagemembersonly}</div><div
class="membersonlypage">|</div>

temp.MainContentWrap {
        G1 >
        G-2 >
        G1G2 >
        G2G1 >
}
[END]

# CT-Only Page

[globalVar = TSFE:page|fe_group = 2] && [usergroup = 2]
temp.PageAccess = TEXT
temp.PageAccess.value = <div class="ctonlytext">Coordination Team Only
Page</div><div class="ctonlypage">|</div>
[END]

temp.MainContent < styles.content.get
temp.MainContent.renderObj.stdWrap.wrap = <div class="content-unit">|</div>
temp.MainContent.renderObj.stdWrap.stdWrap.outerWrap.cObject <
temp.MainContentWrap

temp.MainContentArray = COA
temp.MainContentArray {
        stdWrap.outerWrap.cObject < temp.PageAccess
        10 < temp.PreContent
        20 < temp.MainContent
        20.wrap = <!--TYPO3SEARCH_begin-->|<!--TYPO3SEARCH_end-->
        30 < temp.postContent
}

---

So my subpart is replaced by temp.MainContentArray and then the TS does
the rest. temp.PreContent en temp.PostContent are not specified further
in this example. They're used to insert specific texts and functions
above and below the content elements.

Regards,

Walrick


-- 
webmaster Global Healing Circle
www.globalhealingcircle.net
_______________________________________________
TYPO3-english mailing list
TYPO3-english@lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english

Reply via email to