-- Luiz Vitor <[EMAIL PROTECTED]> wrote
(on Thursday, 24 April 2008, 12:53 PM -0300):
> It wouldn t be convenient when adding a description to an element,
> automatically add the description label?
> 
> Does this make sense?

Yes, it does -- and iirc, I coded the Description decorator to generate
no output if the element description is empty. I am planning on adding
this for 1.6.0, but I'm not sure if I've created an issue for this as of
yet.

> On Thu, Apr 24, 2008 at 11:47 AM, Matthew Weier O'Phinney <[EMAIL PROTECTED]>
> wrote:
> 
>     -- jamest <[EMAIL PROTECTED]> wrote
>     (on Thursday, 24 April 2008, 07:38 AM -0700):
>     > Is there a way to add notes and such within a form?
>     >
>     > I want to be able to add some description text easily readable,
>     preferably
>     > in some <p></p> tags before the text element.
> 
>     use setDescription() (or the 'description' configuration key) to set the
>     text, and then add the 'description' decorator to your element or form.
> 
>     > $form->addElements(array($name_notes,$name));
>     >
>     > So you would ideally get:
>     >
>     > <form....>
>     >
>     > ...
>     > <p>Please enter your full name in the following box.</p>
>     > <dt>Name</dt>
>     > <dd><input .... /></dd>
>     >
>     > ...
>     >
>     > </form>
>     >
>     > Or is there a way to do this that I have missed?
>     >
>     > I am passing the form to the view by using $this->view->form =
>     > $this->getForm();
>     >
>     > So if I continue to do it this way I would need to add the text in 
> within
>     > the form or change the way I pass the form to the view, but I like the
>     way
>     > of padding the whole form over.
> 
>     --
>     Matthew Weier O'Phinney
>     Software Architect       | [EMAIL PROTECTED]
>     Zend - The PHP Company   | http://www.zend.com/
> 
> 

-- 
Matthew Weier O'Phinney
Software Architect       | [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/

Reply via email to