[Typo3] Template problem Images not displaying in FE via Image Content type

Todd Jackson Todd.Jackson at manukau.ac.nz
Wed Aug 24 07:00:13 CEST 2005


I can't get images to display in the FE using any content element e.g. text
w/ images or images - only the thumb image shows in the BE.

However if I change to a pre-set typo3 template in one of my pages, this all
works fine

Therefore it can olny be my typo 3.7.0 template setup, and I have
unsuccessfully tried using the "css_styled_content" template configuration
to display content and images in the FE, I just get blank pages.

I'm also using content(default)& cSet default in my template, as I'm using
the markup as opposed to auto-parser method, and wonder if this is causing a
conflict.

My tt_news extension works fine when uploading image files using the above
method. It only seems to be the page content that I have problems with.

CONSTANTS ###############################################

content {
wrap.header1 = <H1> | </H1>
wrap.header2 = <H2> | </H2>
wrap.header3 = <H3> | </H3>
wrap.header4 = <H4> | </H4>
wrap.bodytext = <P class="p"> | </P>
  case.header1 =  |
  case.header2 =  |
  headerSpace =  0
  space =  0
}

styles.content.textStyle {
face = 
size = 
color = 
}

cSet {
pageColor = #FFFFFF
tableCellColor = #FFFFFF
color = black
color1 = #003366
color2 = #003366
fontFace = Verdana
fontFace.text = Verdana
}

# Image maximum widths, pixels
styles.content.imgtext.maxW = 600

# Activates RTE
content.RTE_compliant = 1

# Indexed Search activated
page.config.index_enable = 1

# last update
styles.content.lastUpdate.label = Last update:
styles.content.lastUpdate.comment_auto = 
styles.content.lastUpdate.wrap = <DIV class="lastupdate"> |</DIV>
styles.content.lastUpdate.format = l, F j, Y


content.defaultSubHeaderType = 3
styles.sitemap.gs.bullet3 = <img src="media/bullets/blackdot.gif" width="2"
height="4" hspace="4" vspace="2" alt="" />
styles.sitemap.gs.bullet2 = <img src="media/bullets/bullet1_n.gif" width="5"
height="9" alt="" />
styles.sitemap.gs.wrap2 = <font size="1" style="font-weight:
normal;">|</font>
styles.sitemap.gs.wrap3 = <font size="1" style="font-weight:
normal;">|</font>
styles.sitemap.gs.wrap1 = <b><font size="1"  color="#4D4D4D"> | </font></b>
styles.sitemap.gs.headerWrap = <div align="center"><b><font size="1"
face="Verdana, Arial, Helvetica, sans-serif" color="#A6000D"> |
</font></b></div>
styles.sitemap.gs.color = #C0C8D4
content.splash.bgCol = #E6EAF0

plugin.alt.print >
plugin.alt.print {
   design for page content. This template file lets you define the position
of page titles and the content.
   file.template = media/scripts/printversion_content.tmpl
   file.stylesheet = 
}

SETUP ##############################


# Externalize CSS and JS
#######################################
config.removeDefaultJS = external
config.inlineStyle2TempFile = 1


# Setting up 'page' to be the default PAGE object (type=0)
#######################################
lib.stdheader.10.stdWrap.wrap >
tt_content.stdWrap.dataWrap = <A name="{field:uid}"></a>
plugin.tx_macinasearchbox_pi1 {
pidSearchpage = 64
}

### News LATEST in right column
lib.newsLatest < plugin.tt_news
lib.newsLatest {
  singlePid = 1
  code >
  code = LATEST
  pid_list >
  pid_list = 1046 # the pids of the pages where the news is stored
  catImageMode = 0
  catTextMode = 0
}
 
page = PAGE
page.typeNum = 0
config.pageTitleFirst = 1
page.stylesheet = fileadmin/templates/mittestudm/styles_hm.css
page.bodyTag = <body leftmargin="0" topmargin="0" marginwidth="0"
marginheight="0">

### JAVASCRIPT JSMENU DEPTNAV
#######################################
page.headerData.5 = TEXT
page.headerData.5.value (
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_jumpMenu(targ,selObj,restore){ //v3.0
//alert(targ+".location='http://mittest.mit/index.php?id="+selObj.options[se
lObj.selectedIndex].value+"'");
eval(targ+".location='http://mittest.mit/index.php?id="+selObj.options[selOb
j.selectedIndex].value+"'");
if (restore) selObj.selectedIndex=0;
}
//-->
</script>
)
### END JAVASCRIPT JSMENU DEPTNAV

page.headerData.10 = TEXT
page.headerData.10.value (
<script type="text/javascript"
src="fileadmin/templates/mittestudm/udm-resources/udm-custom.js"></script>
<script type="text/javascript"
src="fileadmin/templates/mittestudm/udm-resources/udm-control.js"></script>
<script type="text/javascript"
src="fileadmin/templates/mittestudm/udm-resources/udm-style.js"></script>
<script type="text/javascript"
src="fileadmin/templates/mittestudm/udm-resources/udm-x-youarehere.js"></scr
ipt>
)
page.1 = TEMPLATE
page.1.marks.PAGE_UID = TEXT
page.1.marks.PAGE_UID.field = uid
page.1.marks.searchbox >
page.1.marks.searchbox < plugin.tx_macinasearchbox_pi1

page.1  {
   template = FILE
   template.file = fileadmin/templates/mittestudm/template_hm.html   
   workOnSubpart = DOCUMENT_BODY
   subparts.CONTENT_LEFT < styles.content.getLeft
   subparts.CONTENT_RIGHT < styles.content.getRight
   subparts.CONTENT_BORDER < styles.content.getBorder
   subparts.CONTENT < styles.content.get
# add news tmpl to page Object
   subparts.NEWSLATEST < lib.newsLatest

#last update page :
   subparts.LASTUPDATE = TEXT   
   subparts.LASTUPDATE {
     data = page:lastUpdated
     if.isTrue.data = page:lastUpdated
     date = d.M.Y
     wrap = Page updated:&nbsp; |
     data = register : SYS_LASTCHANGED
     if >
   }

# Printer friendly page using PrintLink Ext
#######################################
subparts.PRINT = COA
subparts.PRINT.10 = USER_INT
subparts.PRINT.10.userFunc = tx_open_printlink
subparts.PRINT.20 = HTML
subparts.PRINT.20.value = Printer Friendly Version</A>
subparts.PRINT.wrap = <span class="print-lnk">|</span>
subparts.PRINTIMG = COA
subparts.PRINTIMG.10 = USER_INT
subparts.PRINTIMG.10.userFunc = tx_open_printlink
subparts.PRINTIMG.20 = HTML
subparts.PRINTIMG.20.value = <IMG
SRC="fileadmin/templates/mittestudm/images/print.gif"></A>
subparts.PRINTIMG.wrap = <span class="print-img">|</span>

#Top Graphic menu using GMENU
#######################################
 subparts.TOPNAV = HMENU
 subparts.TOPNAV.special = list
 subparts.TOPNAV.special.value = 6,368,879,254,4,3,2,63
 subparts.TOPNAV.1 = GMENU
 subparts.TOPNAV.1.NO {
   XY = [10.w]+20,20
   backColor = |*| #A70532 |*|
   10 = TEXT
  10.text.field = title
  10.offset = 0,13
  10.align = center
  10.niceText = 1
  10.fontSize = 10
  10.fontColor = white
 }
 subparts.TOPNAV.1.RO < .subparts.TOPNAV.1.NO
 subparts.TOPNAV.1.RO = 1
 subparts.TOPNAV.1.RO {
   10.fontColor = #FF9845
 }
 subparts.TOPNAV.1.ACT < .subparts.TOPNAV.1.NO
 subparts.TOPNAV.1.ACT = 1
 subparts.TOPNAV.1.ACT {
  backColor = #BC0537
  10.fontColor = #FF9845
 }


#Department select form navigation
#######################################
subparts.DEPTNAV  = HMENU
subparts.DEPTNAV.special  = directory
subparts.DEPTNAV.special.value = 281
subparts.DEPTNAV.wrap = <form name="deptform1" style="margin-top: 0;
margin-bottom: 0;"><select name ="jumper"
onChange="MM_jumpMenu('parent',this,0)"><option>Select</option>|</select></f
orm>
subparts.DEPTNAV.1 = TMENU
subparts.DEPTNAV.1.NO {
  expAll = 0 
  doNotLinkIt = 1
  before.data = field:uid
  before.wrap = <option value="|">
  stdWrap.field = title
  stdWrap.wrap = |*| | |*|
  after.wrap = |</option>
}
 
# Left dropdown menu
#######################################
subparts.LEFTNAV = HMENU
subparts.LEFTNAV.special = list
subparts.LEFTNAV.special.value = 6,281,254,4,3,2,63
subparts.LEFTNAV {
wrap = <div id="menu"> | </div>
entryLevel = 0
1 = TMENU
1 {
expAll=1
wrap = <ul id="udm" class="udm"> | </style></ul> 
NO {
wrapItemAndSub = <li> | </li> 
}
}
2 = TMENU
2 {
expAll=1
wrap = <ul id="level2"> | </ul> 
NO {
wrapItemAndSub = <li class="submenu"> | </li> 
}
}
3 = TMENU
3 {
expAll=1
wrap = <ul id="level3"> | </ul> 
NO {
wrapItemAndSub = <li class="submenu"> | </li> 
}
}
4 = TMENU
4 {
expAll=1
wrap = <ul id="level4"> | </ul> 
NO {
wrapItemAndSub = <li class="submenu"> | </li> 
}
}
}

#Sitepath
#################################
#subparts.sitepath = HMENU
#subparts.sitepath.special = rootline
#subparts.sitepath.1 = TMENU
#subparts.sitepath.1.NO.linkWrap = | >&nbsp; |*||*|   |  

# Bottom Navigation Strip
#######################################
   subparts.BTMNAVSTRIP = HMENU
   #subparts.BTMNAVSTRIP.special = directory
   subparts.BTMNAVSTRIP.special = list
   subparts.BTMNAVSTRIP.special.value = 1,2,63,3
   subparts.BTMNAVSTRIP.1 = TMENU
   subparts.BTMNAVSTRIP.1 {
      NO.allWrap = |*||*|<span
class="btmnavstrip">|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#124;&nbsp;&nbsp;&
nbsp;&nbsp;&nbsp;&nbsp;</span>||<span class="btmnavstrip">|</span>
 }

# Bottom Navigation footer
#######################################
   subparts.BTMNAVFOOT = HMENU
   #subparts.BTMNAVFOOT.special = directory
   subparts.BTMNAVFOOT.special = list
   subparts.BTMNAVFOOT.special.value = 4,252
   subparts.BTMNAVFOOT.1 = TMENU
   subparts.BTMNAVFOOT.1 {
      NO.allWrap = |*||*|<span
class="btmnavfoot">|&nbsp;&nbsp;&nbsp;&#124;&nbsp;&nbsp;&nbsp;</span>||<span
class="btmnavfoot">|</span>
 }

#Print Page Setup

######################################
alt_print >
alt_print = PAGE
alt_print.typeNum=98
alt_print.stylesheet = {$plugin.alt.print.file.stylesheet}
 
alt_print.10 = TEMPLATE
alt_print.10 {
  template = FILE
  template.file = {$plugin.alt.print.file.template}
  marks {
    PAGE_TITLE = TEXT
    PAGE_TITLE.field = title
    PAGE_SUBTITLE = TEXT
    PAGE_SUBTITLE.field = subtitle
    PAGE_AUTHOR = TEXT
    PAGE_AUTHOR.field = author
    PAGE_AUTHOR.required=1
    PAGE_AUTHOR.typolink.parameter.field = author_email
    PAGE_UID = TEXT
    PAGE_UID.field = uid
    CONTENT < styles.content.get
  }
  workOnSubpart = DOCUMENT_BODY
}

# Enabling the admin panel for the 'page' PAGE object:
#######################################
page.config.admPanel=1

 

#PREVENTS EXISTING USERGROUPS BEING LOST IF A USER EDITS THEIR PROFILE
#######################################
plugin.feadmin.fe_users.edit.evalValues.usergroup = unsetEmpty


#ASSIGNS DEFAULT USERGROUP UID=1 TO ALL NEW USERS
#######################################
plugin.feadmin.fe_users.create.overrideValues.usergroup = 1


# Spam Protection for Email
#######################################
config {
spamProtectEmailAddresses = 2
spamProtectEmailAddresses_atSubst = (at)
}

plugin.tx_indexedsearch.tableParams.searchRes = border=0 cellpadding=0
cellspacing=0 width="95%"
plugin.tx_indexedsearch.tableParams.secHead = border=0 cellpadding=0
cellspacing=0 width="96%"

plugin.tx_newloginbox_pi3._CSS_DEFAULT_STYLE = 

tt_content.image.20.imgPath = img
plugin.tx_mininews_pi1.listView.results_at_a_time = 5
plugin.tx_mininews_pi1.frontPage.results_at_a_time = 5
plugin.tx_mininews_pi1.listView.maxPages = 5
plugin.tx_mininews_pi1.frontPage.maxPages = 5
plugin.tx_mininews_pi1._CSS_DEFAULT_STYLE = 
plugin.tt_news.displayLatest.image.file.maxW = 136
plugin.tt_news.displayLatest.image.file.maxH = 60
plugin.tt_news.displayLatest.image.file.maxW = 40
page.1.subparts.NEWSLATEST.displayLatest.image.file.maxW = 136
page.1.subparts.NEWSLATEST.displayLatest.image.file.maxH = 67
tt_content.userFunc = 
tt_content.userFunc = tx_cssstyledcontent_pi1->main
tt_content = USER
tt_content = CASE
tt_content.userFunc >

INCLUDE STATIC ######################################

CSet (default)

Content (default)

CSet stylesheet

INCLUDE STATIC (from extensions)######################################

CSS Styled Content (css_styled_content)

CSS-based tmpl (tt_news)

default CSS-styles (tt_news)

 

Regards

Todd.




More information about the TYPO3-english mailing list