TYPO3 Reea Blog

This will be shown to users with no Flash or Javascript.

Lista pagini teaser


lib.pages = COA
lib.pages{

1 = CONTENT
1{
     table = pages
     select {
        pidInList.data = page:uid
        orderBy = sorting
        max = 20
     }
     renderObj = COA
     renderObj {
	 
          wrap = <div> | </div>
          10 = IMAGE
          10.file.import.field = media
          10.file.import = uploads/media/
          10.file.import.listNum = 0
          10.file.width = 110
          10.wrap = | 
          10.required = 1
          10.stdWrap.typolink.parameter.field = uid
          10.stdWrap.typolink.additionalParams.insertData = 1
          10.altText = {field:title}
          10.altText.insertData = 1
	   	   
          20 = TEXT
          20.field = title
          20.typolink.parameter.field = uid
          20.wrap = <h2>|</h2>

          30 = TEXT
          30.field = abstract
          30.wrap = <p>|</p>
	  }
   }

}


Teaser pagini in Sitemap/Menu


#Se introduce in Root / Page Properties / TS
TCEFORM.tt_content.menu_type {
	addItems {
	99 = Page with image (Subpage of Pages selected)
	100 = Page with image (Pages selected)
	}
}

Cod sursa pentru TS in Res


lib.pageWithImageDir = HMENU
lib.pageWithImageDir {
	special = directory
	special.value.field = pages
	includeNotInMenu = 0
	
		1 = TMENU
		1 {
			NO {
			allWrap = <div class="teaserBox">|</div>
			beforeImg {
			import = uploads/media/
			import.field = media
			import.listNum = 0
			width = 152
			height = 138
			}
			beforeImgLink = 1
			beforeWrap = <div class="teaserImage">|</div>
			linkWrap = <div class="teaserTitle">|</div>
		}
	}
}

lib.pageWithImageList = HMENU
lib.pageWithImageList {
	special = list
	special.value.field = pages
	includeNotInMenu = 0
	
		1 = TMENU
		1 {
			NO {
			allWrap = <div class="teaserBox">|</div>
			beforeImg {
			import = uploads/media/
			import.field = media
			import.listNum = 0
			width = 152
			height = 138
			}
			beforeImgLink = 1
			beforeWrap = <div class="teaserImage">|</div>
			linkWrap = <div class="teaserTitle">|</div>
		}
	}
}


tt_content.menu.20 = CASE
tt_content.menu.20.key.field = menu_type
tt_content.menu.20.99 < lib.pageWithImageDir
tt_content.menu.20.100 < lib.pageWithImageList
blog comments powered by Disqus