[TYPO3-german] Wrap um Radio-Buttons

Timo Z. timoz at web.de
Mon Jul 21 09:13:31 CEST 2008


Hallo,

 

ich würde gerne erreichen, dass 

1.	die Radio-Buttons in meinem Formular untereinander stehen inkl. der
Labels
2.	das Label vor dem Fieldset auf gleicher Höhe wie der erste
Radio-Button erscheint

 

Mein Contentrendering ergibt folgendes Bild:

 

[CODE]

<div class="csc-mailform-radio">

                        <label for="mailformRadioButton">Hier ist Ihre
Auswahl</label> 

                        <fieldset id="mailformRadioButton">

                                   <legend>Hier ist Ihre Auswahl:</legend>

                                   <input type="radio" name="RadioButton"
id="mailformRadioButtonOption1" value="Option 1" class="csc-mailform-radio"
/>

                                   <label
for="mailformRadioButtonOption1">Option 1<br /></label>

                                   <input type="radio" name="RadioButton"
id="mailformRadioButtonOption2" value="Option 2" class="csc-mailform-radio"
/>

                                   <label
for="mailformRadioButtonOption2">Option 2<br /></label>

                                   <input type="radio" name="RadioButton"
id="mailformRadioButtonOption3" value="Option 3" class="csc-mailform-radio"
/>

                                   <label
for="mailformRadioButtonOption3">Option 3<br /></label>

                                   <input type="radio" name="RadioButton"
id="mailformRadioButtonOption4" value="Option 4" class="csc-mailform-radio"
/>

                                   <label
for="mailformRadioButtonOption4">Option 4<br /></label>

                        </fieldset>

            </div>

[/CODE]

 

Klar z.T. auch ein CSS-Problem, aber:
wie kann ich erreichen, dass ich um das input-Feld UND das dazugehörige
Label einen div wrappe, so in der Art <div
class=“radiowrap“><input
><label></div>

Meine Idee ist, dass ich die div’s dann nach links floate und immer cleare,
somit bleiben input und label zusammen und erscheinen je Button jeweils
untereinander.

Ich könnte dann auf das Fieldset auch verzichten, aber sobald ich das
###FIELD### in  tt_content.mailform.20.RADIO.layout = <div
class="csc-mailform-radio">###LABEL### ###FIELD###</div> weglasse kommen
meine Radiobuttons nicht mehr (verständlicherweise, da diese ja im Fieldset
stecken). 

 

Vielleicht habt ihr ja auch eine andere Idee wie ich das hinbekomme?

 

Grüße

 

Timo



More information about the TYPO3-german mailing list