[TYPO3] Typoscript in Templavoila

LinTong pcu84424 at hotmail.com
Sun Jun 29 12:24:55 CEST 2008


Hallo Chris

Thanks very much for you response
I am sorry that i am a newbie for tsref. and i tried to override the target, but...
-----------------------------------------------------------------------
            <field_relatedlink type="array">
                <tx_templavoila type="array">
                    <title>related topics</title>
                    <description>related topics</description>
                    <sample_data type="array">
                        <numIndex index="0">related topics</numIndex>
                    </sample_data>
                    <eType>input</eType>
                    <proc type="array">
                        <HSC type="integer">0</HSC>
                    </proc>
                    <TypoScript>

  10 = IMAGE
  10.file = fileadmin/templates/img/relatedlink.jpg
  10.stdWrap.typolink.parameter = 6
***************************************
  10.stdWrap.typolink.target.field = field_relatedlink
***************************************
  10.stdWrap.typolink.parameter.stdWrap.append=TEXT
  10.stdWrap.typolink.parameter.stdWrap.append {
  wrap=#|
  field=field_relatedlink
  }
  
</TypoScript>
                </tx_templavoila>
                <TCEforms type="array">
                    <config type="array">
                        <type>input</type>
                        <size>1</size>
                        <eval>trim</eval>
                    </config>
                    <label>related topics</label>
                </TCEforms>
            </field_relatedlink>
---------------------------------------------------------
But it does not work. the name of the link is still the title of the target page.

Second, the link looks like <a href="...index.php?id=6#cMYINPUT">....</a>. I don't know why there is a character "c"

Thanks very much for your help



> From: chris at oblady.com
> Date: Sun, 29 Jun 2008 11:38:05 +0200
> To: typo3-english at lists.netfielders.de
> Subject: Re: [TYPO3] Typoscript in Templavoila
> 
> Hello,
> 
> first, I didn't notice :
> <HSC type="integer">1</HSC>
> means your content is passed through htmlspecialchars...
> => just delete this line or set it to 0
> 
> 
> for your link text, by default the typolink does this :
> typolink.stdWrap.field=title (the linked page title)
> => you still can use stdWrap over this to do what you need...
> 
> 
> LinTong a écrit :
> > Hallo Chris
> >  
> > Thanks very much for your response.Your code works partly but... at first you can see the source code of XML
> > *********************************************
> >    <field_relatedlink type="array">    <tx_templavoila type="array">     <title>related topics</title>     <description>related topics</description>     <sample_data type="array">      <numIndex index="0">related topics</numIndex>     </sample_data>     <eType>input</eType>     <proc type="array">      <HSC type="integer">1</HSC>     </proc>     <TypoScript>
> >   10 = IMAGE  10.file = fileadmin/templates/img/relatedlink.jpg  10.stdWrap.typolink.parameter = 6
> >   10.stdWrap.typolink.parameter.stdWrap.append=TEXT  10.stdWrap.typolink.parameter.stdWrap.append {  wrap=#|  field=field_relatedlink }
> >  
> > </TypoScript>    </tx_templavoila>    <TCEforms type="array">     <config type="array">      <type>input</type>      <size>1</size>      <eval>trim</eval>     </config>     <label>related topics</label>    </TCEforms>   </field_relatedlink>
> >  
> > ************************************************
> > first problem:It will display as follow:
> >  
> > <a href="index.php?id=6#cMYINPUT" >Research Topic</a> 
> >  
> > it is not a link. that means in source code it looks like
> > &lt;a href=&quot;index.php?id=6#c2222&quot; &gt;Research Topics&lt;/a&gt;
> >  
> > second,the name of the link"Research Topic" is the title of the target page(id = 6). I don't know which part of your code works that way. I would like to display "fixed content"+ MYINPUT.
> >  
> > Third, you can see there is a "c" in front of MYINPUT. I don't know how it comes.
> >  
> > in a word, the link should be <a href="index.php?id=6#MYINPUT" >"fixed content"+ MYINPUT</a> 
> >  
> > However, thanks  very much for your help.
> >  
> >  
> >  
> >  
> >> From: chris at oblady.com> Date: Fri, 27 Jun 2008 18:05:59 +0200> To: typo3-english at lists.netfielders.de> Subject: Re: [TYPO3] Typoscript in Templavoila> > Hello,> > if you read TS Ref, you will see this :> > "Now the input can be an alias or page-id. If the input is an integer> it's a page-id, if it's two comma separated integers, it's a id/type> pair, else it's an alias. For page-id's or aliases you can prepend a "#"> mark with a number indication tt_content record number on the page to> jump to! (if .section-property is present, it overrides this)."> > => if .section-property is present, it overrides this> > means you should code like this :> > <TypoScript>> 10 = IMAGE> 10.file = fileadmin/templates/img/relatedlink.jpg> 10.stdWrap.typolink.parameter = 6> 10.stdWrap.typolink.parameter.stdWrap.append=TEXT> 10.stdWrap.typolink.parameter.stdWrap.append {> wrap=#|> field=field_relatedlink> }> </TypoScript>> > not tested, but should work...> > tell me if it's OK :-)> > LinTong 
> a écrit :> > hallo everybody> > > > > > I modified an image content element in the XML of DS> > > > <TypoScript>> > 10 = IMAGE> > 10.file = fileadmin/templates/img/relatedlink.jpg> > 10.stdWrap.typolink.parameter = 6> > 10.stdWrap.typolink.section.field = field_relatedlink> > </TypoScript>> > > > this add a link "index.php?6#"+the input of field_relatedlink to the image "relatedlink.jpg". it works fine. > > > > but If i want to have a plain input field. e.g. if i input "aaaa", the output will look like:> > <a href="....index.php?6#aaa">related:(this is fixed) aaa </a>> > if "bbb"> > <a href="....index.php?6#bbb">related: bbb </a>> > > > I tried to write codes similar to the above codes but it does not work. Who could do me a favor to show me the correct typoscript which can be add into the XML of templavoila.> > > > Thanks very much.> > > > _________________________________________________________________> > 新年换新颜,快来妆扮自己的MSN给心仪的TA一个惊喜!> > http://im.live
> .cn/emoticons/?ID=18> _______________________________________________> TYPO3-english mailing list> TYPO3-english at lists.netfielders.de> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
> > _________________________________________________________________
> > 用手机MSN聊天写邮件看空间,无限沟通,分享精彩!
> > http://mobile.msn.com.cn/
> _______________________________________________
> TYPO3-english mailing list
> TYPO3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english

_________________________________________________________________
用手机MSN聊天写邮件看空间,无限沟通,分享精彩!
http://mobile.msn.com.cn/


More information about the TYPO3-english mailing list