Search Results

Search found 1 results on 1 pages for 'slkandy'.

Page 1/1 | 1 

  • Setting a label's id in Zend_Form

    - by slkandy
    Hey, guys, I'm trying to set an id for one of my form's labels so I can hide it with jquery later. Here's my element: $password = new Zend_Form_Element_Password('password'); $password->setLabel('Password:') ->setRequired(true) ->addFilter('StripTags') ->addFilter('StringTrim') ->addValidator('NotEmpty') ->setAttrib( "id", "password" ); In the source, it looks like this: <dt> <label for="password" class="required">Password:</label> </dt> <dd> <input type="password" name="password" id="password" value=""> </dd> I need the label to look like: <label id="pass_label" for="password" class="required">Password:</label> Any ideas?

    Read the article

1