ot;Quantity",
>> > >> "disabled"=>"disabled");
>> > >> print $form->hidden('Item.quantityHid');
>> > >> print $form->end('Submit');
>>
>> > >> and then in your controller
>> &g
U could try with:
$form->input('frmInputQuantity', array('label'=>'Quantity:',
'readonly'=>'readonly'));
On 22 Jan., 22:49, Pyrite wrote:
> I want to have a form text input get submitted, but also want it to be
> disabled on display.
>
> Eg. $form->input('frmInputQuantity', array('label'=>'
m.quantityHid');
> > >> print $form->end('Submit');
>
> > >> and then in your controller
> > >> you have to do this
>
> > >> if(!empty($this->data)){
> > >> $this->data['Item']['quantyty] = $this->data['Item'][&
; $this->data['Item']['quantyty] = $this->data['Item']['quantytyHid];
> >> $this->Item->save($this->data['Item']);
>
> >> }
>
> >> i have not tested this yet :P, but i think you could figure it out :)...
quantyty] = $this->data['Item']['quantytyHid];
>> $this->Item->save($this->data['Item']);
>>
>> }
>>
>> i have not tested this yet :P, but i think you could figure it out :)...
>>
>> hope this help..
>>
>
do this
>
> if(!empty($this->data)){
> $this->data['Item']['quantyty] = $this->data['Item']['quantytyHid];
> $this->Item->save($this->data['Item']);
>
> }
>
> i have not tested this yet :P, but i think you could figu
ntytyHid];
$this->Item->save($this->data['Item']);
}
i have not tested this yet :P, but i think you could figure it out :)...
hope this help..
From: Dardo Sordi Bogado
To: cake-php@googlegroups.com
Sent: Friday, January 23, 2009 9:39
> I want to have a form text input get submitted, but also want it to be
> disabled on display.
>From http://www.w3.org/TR/html401/interact/forms.html#h-17.12 :
...the INPUT element is disabled. Therefore, it cannot receive user
input nor will its value be submitted with the form.
you also need
I want to have a form text input get submitted, but also want it to be
disabled on display.
Eg. $form->input('frmInputQuantity', array('label'=>'Quantity:',
'disabled'=>'disabled'));
This does not get submitted into $this->data. How can I change what
gets posted to $this->data with the form help