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

Morten Kjems mortenkjems at gmail.com
Sun Sep 4 18:34:14 CEST 2011


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;)



More information about the TYPO3-english mailing list