[TYPO3-templavoila] FCE - Image with checkbox to select if 'click enlarge in lightbox' or not

Ian Solo ian at webian.it
Wed Aug 29 21:10:45 CEST 2007


Hi TV ppl!
I would like to set an FCE with an image and a checkbox to select if the 
image will enlarge or not with Lightbox.

Step by step, i made this:

1.
I installed the extension kj_imagelightbox2.

2.
I made a DS with a field_image with this typoscript:
--------------------------------
<![CDATA[
 10 = IMAGE
 10.file.import = uploads/tx_templavoila/
 10.file.import.current = 1
 10.file.import.listNum = 0

 10.imageLightbox2 = 1
]]>
--------------------------------
The image can now be enlarged with Lightbox

3.
I modified the DS to add a field_enlarge as a checkbox to let the editor 
select if he want to enlarge or not the image.
This is the XML of the field_enlarge:
--------------------------------
   <field_enlarge type="array">
    <type>no_map</type>
    <tx_templavoila type="array">
     <title>enlarge?</title>
     <sample_data type="array">
      <numIndex index="0"></numIndex>
     </sample_data>
     <eType>int</eType>
    </tx_templavoila>
    <TCEforms type="array">
     <config type="array">
      <type>check</type>
      <eval>int</eval>
      <default type="integer">1</default>
     </config>
     <label>enlarge?</label>
    </TCEforms>
   </field_enlarge>
--------------------------------
Now in the BE the FCE have this new working checkbox.

4.
I modified the typoscript of the field_image to check if the checkbox works, 
I added those 2 lines:
--------------------------------
 20 = TEXT
 20.field = field_enlarge
--------------------------------
Now the FCE renders in the FE showing the image and the value of the 
checkbox field_enlarge ( value 0 or 1 ).

5.
Now there's the problem. I tryed many ways to pass the value of the checkbox 
to the typoscript of the field_image at this point:
--------------------------------
10.imageLightbox2 = <value of the checkbox>
--------------------------------

but i can't find the way to pass it.

I tryed:
--------------------------------
10.imageLightbox2 = field_enlarge
--------------------------------
10.imageLightbox2.field = field_enlarge
--------------------------------
10.imageLightbox2.data = field:field_enlarge
--------------------------------
10.imageLightbox2 < field_enlarge
--------------------------------
temp.enlarge = TEXT
temp.enlarge.field = field_enlarge
10.imageLightbox2 < temp.enlarge
--------------------------------

But none worked for me.

Any tips please?

Bye!ian 




More information about the TYPO3-project-templavoila mailing list