1

現在の画像ファイル名を取得する方法を教えてもらえますか?ライトボックスで開くには、現在の画像をリンクする必要があります。

私のコード:

15 = TEXT
    15 {
      field = image
      split {


        token = ,
        cObjNum = 1 || 3 || 3


        //ignore
        1....


        3 {
          10 = IMAGE
          10.file.import.current = 1
          10.file.import = uploads/pics/
          10.file.maxW = 270
          10.params = class="hidden"

          10.imageLinkWrap = 1
          10.imageLinkWrap {
            enable = 1
            typolink.parameter = TEXT
            typolink.parameter.field = image
            typolink.parameter.listNum.splitChar = ,

            typolink.parameter.listNum = // <- Need current image number
            typolink.parameter.wrap = /uploads/pics/|
4

2 に答える 2

3

imgのメインピュレーション中にいくつかの特別な変数を設定する必要があります。TYPO3wikiから

IMG_RESOURCE:img_resourceのレンダリング中にTYPO3は画像情報の数値配列であるTSFE:lastImgResourceInfoを設定します

TSFE:lastImgResourceInfo|0 contains the width (after scaling) of the image
TSFE:lastImgResourceInfo|1 contains the height (after scaling) of the image
TSFE:lastImgResourceInfo|2 contains the image file extension
TSFE:lastImgResourceInfo|3 contains the path to the (scaled) image file
TSFE:lastImgResourceInfo|origFile contains the name (path?) of the original file
TSFE:lastImgResourceInfo|origFile_mtime contains the the last modification time of the original file

したがって、たとえばデータでそれらを使用できます

10 = TEXT
10.data = TSFE:lastImgResourceInfo|3
于 2012-12-03T10:23:17.457 に答える
0

http://wiki.typo3.org/TSref/stdWrap#current http://www.typo3wizard.com/de/snippets/general-config/bild-aus-media-feld.html

フィールド「画像」

lib.images=TEXT
lib.images.data= levelmedia: 2,slide
lib.images.wrap=<div id="bilder">|</div>
lib.images.split{
token=,
cObjNum=1
1.10=IMAGE
1.10.file{
 import.current=1
 import=uploads/media/
 width = 270
 height= 300
}
} 
于 2012-12-03T14:02:32.103 に答える