Re: Updating FormBuilder broke the dynamic QuickForm renderer
| From: | Justin Patrin | Date: | Fri, 08 Jul 2005 03:41:35 +0000 |
| Subject: | Re: Updating FormBuilder broke the dynamic QuickForm renderer | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-19910@lists.php.net to get a copy of this message | ||
On 7/7/05, Justin Patrin <papercrane@gmail.com> wrote:
> On 7/7/05, Dan Rossi <pear@electroteque.org> wrote:
> >
> > On 08/07/2005, at 12:39 PM, Justin Patrin wrote:
> >
> >
> > Its not an issue in the template as all i am doing is looping through
> > the qf object. How can i revert back to older versions ?
> >
> > QuickformForm Object
> > (
> > [frozen] =>
> > [javascript] =>
> > [attributes] =>
> > action="/hardgayfeeds/accounts.hardgayfeeds.com/index.php"
> > method="post" name="dataobjects_customers"
> > id="dataobjects_customers"
> > target="_self"
> > [requirednote] => <span style="font-size:80%;
> > color:#ff0000;">*</span><span style="font-size:80%;">
> > denotes required
> > field</span>
> > [hidden] => <input name="_qf__dataobjects_customers"
> > type="hidden"
> > value="" />
> > <input name="customerID" type="hidden" value="57" />
> >
> > [errors] => stdClass Object
> > (
> > )
> >
> > [elements] =>
> > [sections] => Array
> > (
> > [0] => stdClass Object
> > (
> > [header] => customers
> > [elements] => Array
> > (
> > [0] => QuickformElement Object
> > (
> > [name] => customer_name
> > [value] => snipped
> > [type] => text
> > [frozen] =>
> > [label] => Customer Name
> > [required] =>
> > [error] =>
> > [style] =>
> > [html] => <input
> > name="customer_name" type="text" value="snipped" />
> > [separator] =>
> > [elements] =>
> > )
> > //elements snipped from post
> >
> >
> > [11] => QuickformElement Object
> > (
> > [name] => request
> > [value] => Request Details Update
> > [type] => button
> > [frozen] =>
> > [label] =>
> > [required] =>
> > [error] =>
> > [style] =>
> > [html] => <input
> > onclick="javascript: data =
> > aframe_compact_data('customer_name',this.form.customer_name.value,'conta
> >
> > ct_name',this.form.contact_name.value,'city',this.form.city.value,'state
> >
> > ',this.form.state.value,'post_code',this.form.post_code.value,'country',
> >
> > this.form.country.value,'phone',this.form.phone.value,'email',this.form..
> >
> > email.value,'billing_email',this.form.billing_email.value,'tech_email',t
> > his.form.tech_email.value,'address',this.form.address.value);
> > aframe_call_service('POST','Aframe_Details_Request',
> > 'request.php',
> > request_result, data);" name="request" value="Request Details
> > Update"
> > type="button" />
> > [separator] =>
> > [elements] =>
> > )
> >
> > )
> >
> > )
> >
> > )
> >
> > )
> >
> >
>
> Ummm...this doesn't look like a QF to me. It looks like whatever
> object you're rendering. A QF object should have _elements and would
> definately have the element in it. Again, did you also upgrade QF?
>
> How is this object that your print_r'ed above created?
>
A cursory glance at the ObjectFlexy renderer shows:
/**
* Array of QuickformElementObject elements. If there are
headers in the form
* this will be empty and the elements will be in the
* separate sections
* @var array $elements
*/
var $elements;
/**
* Array of sections contained in the document
* @var array $sections
*/
var $sections;
So if there's a header there's nothing in elements. Try setting
addFormHeader to false (FB option).
--
Justin Patrin