Hallo,
ich hoffe bei diesem schönen Wetter ist jemand online und kann mir meine Frage beantworten;-)
möchte eine Auswahl mit all meinen Seminaren automatisch über TS erzeugen
Titel hab ich ausgelesen - das er das Datum des jeweiligen Seminars noch mit aufnimmt hab ich auch geschafft nur spuckt er jetzt diese blöden Zahlen aus der Datenbank rein also z.B 1244883540 wie kann ich diese Zahlen jetzt zu einem richtigen Datum auflösen <- sagt man das so?
hier mein TS
# Auswahlliste Seminare
lib.seminar = COA_INT
lib.seminar {
10 = TEXT
10.value = <div id="powermaildiv_uid34" class="tx_powermail_pi1_fieldwrap_html tx_powermail_pi1_fieldwrap_html_text tx_powermail_pi1_fieldwrap_html_34 odd"><label for="uid50">Seminare</label>
20 = CONTENT
20.wrap = <select id="uid50" name="tx_powermail_pi1[uid50]" style="width:300px">|</select></div>
20 {
table = tx_seminars_seminars
select {
pidInList = 110
orderBy = title
}
renderObj = COA
renderObj {
10 = COA
10 {
10 = TEXT
10.dataWrap = <option value="{field:title}" style="width:300px">{field:begin_date} - {field:title}</option>
10.insertData = 1
}
}
}
}
danke schon mal
müsste dann also so aussehen oder?
10.conf.tx_seminars_seminars.strftime = %d.%m.%Y
nur wie bau ich das ganze dann in mein TS ein - so funktionierts nicht :-(
# Auswahlliste der angebotenen Kurse
lib.seminar = COA_INT
lib.seminar {
10 = TEXT
10.value = <div id="powermaildiv_uid34" class="tx_powermail_pi1_fieldwrap_html tx_powermail_pi1_fieldwrap_html_text tx_powermail_pi1_fieldwrap_html_34 odd"><label for="uid50">Seminare</label>
20 = CONTENT
20.wrap = <select id="uid50" name="tx_powermail_pi1[uid50]" style="width:300px">|</select></div>
20 {
table = tx_seminars_seminars
select {
pidInList = 110
orderBy = title
}
renderObj = COA
renderObj {
10 = COA
10 {
10 = TEXT
10.dataWrap = <option value="{field:title}" style="width:300px"> | {field:title}</option>
10.conf.tx_seminars_seminars.field = begin_date
10.conf.tx_seminars_seminars.strftime = %A, %d.%m.%Y
10.insertData = 1
}
}
}
}
so habs damit hinbekommen
renderObj = COA
renderObj {
10 = COA
10 = TEXT
10.field = begin_date
10.strftime = %d.%m.%Y
10.wrap = <option value="{field:title}" style="width:300px"> | - {field:title}</option>
10.insertData = 1
}
Hallo!
Ich habe ein bisschen anderes Problem aber ich schreibe es trotzdem hier:
ich möchte von Seminars ext. das Datum und einen TerminTitle an powermail übergeben.
ich mache es so:
temp.datebegin = TEXT
temp.datebegin {
data = GP:tx_seminars_pi1|showUid
wrap = {DB:tx_seminars_seminars:|:begin_date}
insertData = 1
}
lib.meindatum = COA
lib.meindatum {
10 = COA
10 {
10 = TEXT
10 < temp.datebegin
stdWrap.date = d.m.Y
stdWrap.wrap = | -
}
20 = TEXT
20 {
data = GP:tx_seminars_pi1|showUid
wrap = {DB:tx_seminars_seminars:|:title}
insertData = 1
}
}
plugin.tx_powermail_pi1.dynamicTyposcript = COA
plugin.tx_powermail_pi1.dynamicTyposcript {
test < lib.meindatum
}
es klappt so weit gut, es kommt dann so aus:
"11.03.2011 - Test Seminar"
aber wenn ich im seminars ext. das Feld "Datum" frei lasse, kommt es so aus:
"01.01.1970 - Test Seminar"
und ich glaube das ist normal, weil das Wert 0 übergeben wird.
nun möchte ich, dass in dem Fall kein Datum steht. Ich vermute, dass das mit einer if Abfrage möglich wäre, aber wie geht es im Typoscript und in dem Fall genau?
Ich habe schon alle Tutorials für IF Abfrage in Typoscript gelesen, aber es klappt bei mir nicht.. 😢
Bitte um Hilfe! #paralyzed#
Danke!