Hi!

Sorry for my non-perfect english ^^

After creating an own browser-game with php (without Zend) I am now trying
to learn Zend ... This time I am developing a web-community with some
people. For this we use the Zend-Framework. All I didn't knew yet I was able
to let google and documentations help me - without any problems furthermore.

But I can search for hours - for this problem I can't find a solution at
all!

I have to use html-code in Label's. So I use this Code for
Label-Decorator's:

    public static function getHtmlLabelDecorator()
      {
          return array(
              'ViewHelper',
              array('Label', array('escape' => false))
          );
      }

and it works great with most element-type's.

But with Radio-Buttons it generates this sort of Code-Output:

    <dt id="profilfoto-label"><label
class="optional">&lt;br/&gt;&lt;br/&gt;&lt;h1&gt;Dinge, die du
denkst&lt;/h1&gt;&lt;br/&gt;Ist es dir wichtig, dass dein Gegen?ber ein Foto
von sich im Profil hat?&lt;br/&gt;</label></dt>

    <label for="profilfoto-1"><input type="radio" name="profilfoto"
id="profilfoto-1" value="1" />Ja</label><br /><label
for="profilfoto-2"><input type="radio" name="profilfoto" id="profilfoto-2"
value="2" />Nein</label>

in the code it looks like this:

    $this->addElement('radio', 'profilfoto', array(
                'id'           => 'profilfoto',
                'name'         => 'profilfoto',
                'label'        => '<br/><br/><h1>Dinge, die du
denkst</h1><br/>Ist es dir wichtig, dass dein Gegen?ber ein Foto von sich im
Profil hat?<br/>',
                'Decorators'   =>
HimmlischPlaudern_Util_Constants::getHtmlLabelDecorator(),
                'required'     => false,
                'multiOptions' =>
HimmlischPlaudern_Util_Constants::getGenerelAnswerArray()
            ));

With all other elements with which I use this decorator-function, it works
really great - for example with textarea oder a simple text-input-field.

Can anyone help me changing the function getHtmlLabelDecorator() in order to
get the html-code-output dislayed correcty instead of constructions like &gt
like above?!? ...

hoping to find help here!

kind regards from germany,

Dennis
-- 
View this message in context: 
http://zend-framework-community.634137.n4.nabble.com/Zend-Form-Radio-Button-Decorator-tp3228366p3228366.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to