[TYPO3-english] Get file size with typoscript? or some other way?

Kay Strobach typo3 at kay-strobach.de
Sun Sep 4 18:58:24 CEST 2011


Hi,

registers should to the trick ;)

Regards
Kay

Am 04.09.2011 18:34, schrieb Morten Kjems:
> Thanks for pointing me in the right direction Kay.
> 
> I can make it work with the following code (I am using the Generic
> Marker extension):
> 
> mp4size = TEXT
> mp4size {
>   field = generic_tx_mknewfields_videofile
>   filelink {
>     path = fileadmin/folder/videos/project/
>     size = 1
>   }
> }
> 
> That will output a link to the file and the raw filesize right after the
> link. Great!
> 
> However I still face some challenges.
> 
> 1. The path is not the same for each file. So I need to build the path
> dynamically.
> 
> I can do this easily since the file and the folder are named almost the
> same.
> 
> mp4path = COA
> mp4path.10 = TEXT
> mp4path.10 {
> field = generic_tx_mknewfields_videofile
> split {
>       token = _controller.swf
>       cObjNum = |*|1|*|2
>       1.current = 1
>       1.noTrimWrap = ||/|
>       2.current = 1
>    }
> wrap = {$baseURL}fileadmin/{$mappe}/videos/|
> }
> 
> This will give me the correct path but how do I write that path equals
> the code above?
> 
> Something like
> path = and then my snippet.
> 
> All help is appreciated.
> 
> Den 04-Sep-11 16:07, Kay Strobach skrev:
>> please take a look in the TS for the filelinks content element in css
>> styled content;)
>> There should be an example;)
> 


-- 
http://www.kay-strobach.de - Open Source Rocks

TYPO3 .... inspiring people to share!
Get involved: http://typo3.org

Answere was usefull: https://flattr.com/profile/kaystrobach


More information about the TYPO3-english mailing list