本文整理汇总了PHP中Textarea::setId方法的典型用法代码示例。如果您正苦于以下问题:PHP Textarea::setId方法的具体用法?PHP Textarea::setId怎么用?PHP Textarea::setId使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Textarea
的用法示例。
在下文中一共展示了Textarea::setId方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: testVerificaSeOsDadosForamInseridos
public function testVerificaSeOsDadosForamInseridos()
{
$textarea = new Textarea();
$textarea->setId("textareaMsg");
$textarea->setName("mensagem");
$textarea->setClass("form-control");
$textarea->setProtected("protected");
$textarea->setLabel("Mensagem");
$textarea->setAlert("Erro no field.");
$textarea->setValue("valor");
$textarea->setRows(2);
$this->assertEquals("textareaMsg", $textarea->getId());
$this->assertEquals("mensagem", $textarea->getName());
$this->assertEquals("form-control", $textarea->getClass());
$this->assertEquals("protected", $textarea->getProtected());
$this->assertEquals("Mensagem", $textarea->getLabel());
$this->assertEquals("Erro no field.", $textarea->getAlert());
$this->assertEquals("valor", $textarea->getValue());
$this->assertEquals(2, $textarea->getRows());
}
示例2: __construct
public function __construct($widgetUniqName = null, $content = null)
{
parent::__construct('about_me_form');
$this->widgetUniqName = $widgetUniqName;
$this->setAjax(true);
$this->setAction(OW::getRouter()->urlFor('BASE_CTRL_ComponentPanel', 'ajaxSaveAboutMe'));
$input = new Textarea('about_me');
$input->addAttribute('style', 'width: 93%');
$input->setId('about_me_widget_input');
$input->setHasInvitation(true);
$input->setInvitation(OW::getLanguage()->text('base', 'about_me_widget_inv_text'));
//$input->setRequired(true);
$input->setValue($content);
$this->addElement($input);
$hidden = new HiddenField('widget_uniq_name');
$hidden->setValue($widgetUniqName);
$this->addElement($hidden);
$submit = new Submit('save');
//$submit->setLabel(OW::getLanguage()->text('base', 'widget_about_me_save_btn'));
$this->addElement($submit);
OW::getDocument()->addOnloadScript('
window.owForms["about_me_form"].bind("success", function(data){
OW.info(data.message);
});
window.owForms["about_me_form"].reset = false;
');
}
示例3: Body
$head->setTitle('PSA - query');
$head->setCss('./css/psa.css');
$head->setJs('./js/PSA.js');
$head->build();
$body = new Body();
$body->build();
include_once './inc/menubar.php';
$body->line('Insert raw sql query : ');
$form = new Form();
$form->setAction('controller.php');
$form->build();
$inp_text = new Textarea();
$inp_text->setRows(15);
$inp_text->setCols(70);
$inp_text->setName('qs');
$inp_text->setId('to_text');
$inp_text->build();
$body->line();
$cmd->build();
$submit->build();
unset($form);
$body->line('<hr />');
$psa = new PDO("sqlite:./data/base.sqlite");
$q = "SELECT * FROM queries ORDER BY datum DESC LIMIT 10";
$tps = $psa->prepare($q);
$tps->execute();
$res = $tps->fetchAll();
if (!$res) {
$body->line('no queries found.');
} else {
$table = new Table();