Add div tag in quickform

Add div tag in quickform

by Lei Zhang -
Number of replies: 2
Has anyone tried to apply YUI ajax in a form before? Is there anyway I can chuck in a div tag inside a form just to rending an effect? no echo pleasesmile


Average of ratings: -
In reply to Lei Zhang

Re: Add div tag in quickform

by Mark Johnson -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
$mform->addElement('html', '<div id="hello">');
$mform->addElement($some_elements, ...);
$mform->addElement('html', '</div>');

Applying YUI functions to a Moodle Form is just like applying them to any other element. You might need a bit of trickery with radio buttons and check boxes which don't always have the id attribute you'd expect, I usually define them manually in the $attributes parameter.
Average of ratings: Useful (1)
In reply to Lei Zhang

Re: Add div tag in quickform

by Martin Contreras -

Hi Lei,

Did you resolve your problem ? If yes, can you help me, I have the same problem. I´d like to use YUI ajax

Thanks in advance