[TYPO3-mvc] CObject-ViewHelper to output several images

Daniel Schöne daniel at schoene.it
Fri Jan 27 13:55:00 CET 2012


Hi Michael,

you might want to consider using http://fedext.net/fed-viewhelpers/resource/image/ ;)

cheers,
Daniel

On Jan 27, 2012, at 1:47 PM, Alexander Dick wrote:

> Hi,
> 
> are you 100% sure that your images reside in uploads/pics/ ?
> Maybe it's the wrong directory.
> 
> kind regards
> Alex
> 
> Am 27.01.2012 12:52, schrieb Michael Bakonyi:
>> Hi everybody,
>> 
>> I'd like to use the CObject-ViewHelper to render images from a standard
>> backend-field with TCA-type of "group", where the image-filenames are
>> divided by colon as usual.
>> 
>> So I set up the ViewHelper by fetching my Object:
>> 
>> <f:cObject typoscriptObjectPath="lib.image" data="{project}" />
>> 
>> And in TS I try to access the mentioned field/property:
>> 
>> lib.image = TEXT
>> lib.image{
>>   field = galleryImages
>>   field.split{
>>     token = ,
>>     cObjNum = 1
>>     1{
>>       10 = IMAGE
>>       10{
>>         file{
>>           import = uploads/pics/
>>           import.current = 1
>>           maxW = 272
>>         }
>>       }
>>     }
>>   }
>> }
>> 
>> Nothing special here, but the ViewHelper neither outputs anything nor
>> does it report any error-message, whereas this is working:
>> 
>> lib.image = TEXT
>> lib.image{
>>   field = galleryImages
>>   field.split{
>>     token = ,
>>     cObjNum = 1
>>     1{
>>       10 = TEXT
>>       10{
>> 	current = 1
>>       }
>>     }
>>   }
>> }
>> 
>> I don't want to build my own ViewHelper here as I would then have to
>> care about scaling and so on which I think is already there via TS and
>> just has to be used.
>> 
>> (I also wanted to use the stated attribute "current" for the ViewHelper
>> but strangely then the error-message appears that it was not registered
>> (using Extbase/Fluid 1.3.0). I couldn't find a bug-report about this
>> issue – anybody else having problems with this in 4.5.10?)
>> 
>> Would be great if someone would have a hint for me so that I can move on
>> in the right direction.
>> 
>> Cheers,
>> Michael
> 
> _______________________________________________
> TYPO3-project-typo3v4mvc mailing list
> TYPO3-project-typo3v4mvc at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc

-- 
Daniel Schöne


tel.: (0351) 25 38 138
mobil: (0178) 14 81 505
email: daniel at schoene.it
web: http://schoene.it

USt-IdNr.: DE 264 29 88 81



More information about the TYPO3-project-typo3v4mvc mailing list