本文整理汇总了PHP中ZurmoHtml::activeName方法的典型用法代码示例。如果您正苦于以下问题:PHP ZurmoHtml::activeName方法的具体用法?PHP ZurmoHtml::activeName怎么用?PHP ZurmoHtml::activeName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ZurmoHtml
的用法示例。
在下文中一共展示了ZurmoHtml::activeName方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: renderHiddenField
protected function renderHiddenField(&$hiddenElements, $attributeName, $value = null)
{
$hiddenElements .= ZurmoHtml::hiddenField(ZurmoHtml::activeName($this->model, $attributeName), $value, array('id' => ZurmoHtml::activeId($this->model, $attributeName)));
}
示例2: renderHiddenField
/**
* Render and return a hiddenField.
* @param $attributeName
* @param $value
* @return string
*/
protected final function renderHiddenField($attributeName, $value)
{
return ZurmoHtml::hiddenField(ZurmoHtml::activeName($this->model, $attributeName), $value, array('id' => ZurmoHtml::activeId($this->model, $attributeName)));
}
示例3: resolveModuleClassNameJQuerySelector
protected function resolveModuleClassNameJQuerySelector()
{
$name = ZurmoHtml::activeName($this->model, 'modelClassName');
$selector = "select[name^=\"{$name}\"]";
return $selector;
}
示例4: renderSendGridEditableTextField
/**
* Render sendgrid editable text field
* @param CModel $model
* @param CFormModel $form
* @param string $attribute
* @param boolean $isPassword
* @return string
*/
public function renderSendGridEditableTextField($model, $form, $attribute, $isPassword = false)
{
$id = ZurmoHtml::activeId($model, $attribute);
$name = ZurmoHtml::activeName($model, $attribute);
$htmlOptions = array('name' => $name, 'id' => $id);
$label = $form->labelEx($model, $attribute, array('for' => $id));
if (!$isPassword) {
$textField = $form->textField($model, $attribute, $htmlOptions);
} else {
$textField = $form->passwordField($model, $attribute, $htmlOptions);
}
$error = $form->error($model, $attribute);
return '<div>' . $label . $textField . $error . '</div>';
}