[TYPO3-german] Alternatives Bild (Browser Extension) - tt_content.image.20?

Thomas Hirt info at thomas-hirt.at
Sun Nov 4 12:15:49 CET 2012


Danke David!

Genau so habe ich es auch gemacht:

 > ohnen deinen Code weir gelesen zu haben, ist if.isTrue und if.isFalse sollten Deine Freunde sein.

		
	image = COA
           image {
             10 = COA
             10.if.isTrue = ###FE_USERS.IMAGE###
             10 {
               10 < tt_content.image.20
               10 {
                 imgList.field >
                 imgList = ###FE_USERS.IMAGE###
                 #imgPath = uploads/pics/
                 imgPath = fileadmin/dateien/lehrerinnen/
                 imgMax = 1
                 1 {
                   file = fileadmin/dateien/lehrerinnen/test.jpg
                   file {
                     width.field >
                     #maxW = 90
                     #maxH = 90
                     width = 70
                     import.current = 1
                   }
                   altText.field >
                   altText = ###FE_USERS.TITLE### ###FE_USERS.FIRST_NAME### ###FE_USERS.LAST_NAME###
                   titleText.field >
                   titleText = ###FE_USERS.TITLE### ###FE_USERS.FIRST_NAME### ###FE_USERS.LAST_NAME###
                   imageLinkWrap >
                   imageLinkWrap = 1
                   imageLinkWrap {
                     enable = 1
                     typolink {
                       parameter.cObject = IMG_RESOURCE
                       parameter.cObject.file.import.data = TSFE:lastImageInfo|origFile
                       parameter.override.field = image_link
                       parameter.override.listNum.stdWrap.data = register : IMAGE_NUM_CURRENT
                       parameter.override.if.isTrue.field = image_link
                       title.field = imagecaption // header
                       title.split.token.char = 10
                       title.split.returnKey.data = register : IMAGE_NUM_CURRENT
                       ATagParams = rel="fancybox" class="fancybox"
                       ATagParams.override = rel="fancybox{field:uid}" class="fancybox"
                       ATagParams.insertData = 1
                     }
                   }
                 }
               }
             }

             20 = COA
             20.if.isFalse = ###FE_USERS.IMAGE###
             20 {
               10 = IMAGE
               10 {
                 file = fileadmin/dateien/lehrerinnen/test.jpg
                 file.width = 70c
                 file.height = 90c
               }
             }

           }

Gruß,
Thomas


Am 04.11.12 10:15, schrieb d.ros:
> Am 03.11.2012 19:20, schrieb Thomas Hirt:
>> Liebe Community!
>>
>> Ich habe unten stehenden Typoscript Code für die Browser Extension
>> laufen und hätte gerne ein alternatives Bild, falls keines vorhanden
>> ist. Hat jemand eine Idee wie das umzusetzen ist?
>>
>> Eigentlich werden hier die Eigenschaften von tt_content.image.20 kopiert...
>>
>> Danke im Voraus für jeden Tipp,
>> Thomas
>>
>>
>> ###############
>>
>> plugin.tx_browser_pi1 {
>>
>> # Verhindern, dass die Broser Extension die Links automatisch macht,
>> da sie manuell gewrappt werden.
>> general_stdWrap.parseFunc.makelinks = 0
>>
>> template {
>> file =
>> fileadmin/template_dateien/templates_ext/lehrerinnen-browser_template.html
>> }
>>
>> views {
>> list {
>> 1 {
>>
>> name = LehrerInnen
>> select (
>> fe_users.last_name,
>> fe_users.first_name,
>> fe_users.title,
>> fe_users.email,
>> fe_users.image
>> )
>>
>> csvLinkToSingleView = fe_users.email
>>
>> search = fe_users.last_name, fe_users.first_name
>>
>> fe_users {
>> first_name = COA
>> first_name.10 = TEXT
>> first_name.10 {
>> // hier werden field1 und field2 in einen Marker gesetzt
>> value = ###FE_USERS.TITLE### ###FE_USERS.FIRST_NAME###
>> ###FE_USERS.LAST_NAME###
>> }
>>
>> email = COA
>> email {
>> 10 = TEXT
>> 10 {
>> value = ###FE_USERS.EMAIL###
>> wrap = <div class="fe-users-list-email"><link
>> mailto:|>Email</link></div>
>> }
>> }
>>
>> image < tt_content.image.20
>> image {
>> imgList.field >
>> imgList = ###FE_USERS.IMAGE###
>> #imgPath = uploads/pics/
>> imgPath = fileadmin/dateien/lehrerinnen/
>> imgMax = 1
>> 1 {
>> file = fileadmin/dateien/lehrerinnen/test.jpg
>> file {
>> width.field >
>> maxW = 90
>> maxH = 90
>> import.current = 1
>> }
>> altText.field >
>> altText = ###FE_USERS.TITLE### ###FE_USERS.FIRST_NAME###
>> ###FE_USERS.LAST_NAME###
>> titleText.field >
>> titleText = ###FE_USERS.TITLE###
>> ###FE_USERS.FIRST_NAME### ###FE_USERS.LAST_NAME###
>> imageLinkWrap >
>> imageLinkWrap = 1
>> imageLinkWrap {
>> enable = 1
>> typolink {
>> parameter.cObject = IMG_RESOURCE
>> parameter.cObject.file.import.data =
>> TSFE:lastImageInfo|origFile
>> parameter.override.field = image_link
>> parameter.override.listNum.stdWrap.data = register :
>> IMAGE_NUM_CURRENT
>> parameter.override.if.isTrue.field = image_link
>> title.field = imagecaption // header
>> title.split.token.char = 10
>> title.split.returnKey.data = register :
>> IMAGE_NUM_CURRENT
>> ATagParams = rel="fancybox" class="fancybox"
>> ATagParams.override = rel="fancybox{field:uid}"
>> class="fancybox"
>> ATagParams.insertData = 1
>> }
>> }
>> }
>> }
>> }
>>
>> // Bereinigung der Felder. Field2 wird nicht ausgegeben. Im
>> // HTML-Template ist nur ein Marker für ###TABLE.FIELD1###
>> functions {
>> clean_up {
>> csvTableFields = fe_users.title, fe_users.last_name
>> }
>> }
>>
>> // [String] Order By clause (don't confuse it with the SQL
>> Order By)
>> orderBy (
>> fe_users.last_name ASC, fe_users.first_name
>> )
>>
>> marker {
>> my_reset {
>> value = zurück
>> }
>>
>> my_url {
>> value = ueber-uns/lehrerteam.html
>> }
>>
>>
>> my_search {
>> value = suchen
>> }
>>
>> bildlabel {
>> value = Bild
>> }
>> }
>> }
>> }
>>
>> }
>> }
>




More information about the TYPO3-german mailing list