hi,
Controller:
class ConfigurationsController extends AppController {
public $components = array(
'Security'
);
public function index(){
/*..................*/
}
}
public $components = array(
'Security'
);
public function index(){
/*..................*/
}
}
View:
<?php
echo $this->Form->create('Configurations');
echo $this->Form->input('Trader.name');
echo $this->Form->create('Configurations');
echo $this->Form->input('Trader.name');
/****
Settings:
table: traders
column: has_ftp tinyint(1)
View Result:
<div class="input checkbox">
<input type="hidden" value="0" id="TraderHasFtp_" name="data[Trader][has_ftp]">
<input type="checkbox" id="TraderHasFtp" value="1" name="data[Trader][has_ftp]">
<label for="TraderHasFtp">Has Ftp</label>
</div>
Question:
Why create the FormHelper an additional hidden input field?!?!?!
****/
echo $this->Form->input('Trader.has_ftp');
echo $this->Form->input('Ftp.ftp_server');
echo $this->Form->input('Ftp.ftp_login_name');
echo $this->Form->input('Ftp.ftp_password');
echo $this->Form->input('Ftp.root_directory');
echo $this->Form->input('Trader.has_ftp');
echo $this->Form->input('Ftp.ftp_server');
echo $this->Form->input('Ftp.ftp_login_name');
echo $this->Form->input('Ftp.ftp_password');
echo $this->Form->input('Ftp.root_directory');
/****
Settings:
table: ftps
column: vendor tinyint(1)
View Result:
<div class="input text"><label for="FtpVendor">Vendor</label>
<input type="text" id="FtpVendor" name="data[Ftp][vendor]">
</div>
Question:
The FormHelper creates an input field instead of a checkbox!?!?!
***/
echo $this->Form->input('Ftp.vendor');
echo $this->Form->end('Absenden');
//What i´m doing wrong?
No comments:
Post a Comment