本文整理汇总了PHP中ZurmoHtml::tag方法的典型用法代码示例。如果您正苦于以下问题:PHP ZurmoHtml::tag方法的具体用法?PHP ZurmoHtml::tag怎么用?PHP ZurmoHtml::tag使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ZurmoHtml
的用法示例。
在下文中一共展示了ZurmoHtml::tag方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: renderMergeTagsContent
protected function renderMergeTagsContent()
{
$title = ZurmoHtml::tag('h3', array(), Zurmo::t('Default', 'Merge Tags'));
$view = new MergeTagsView('Campaign', Element::resolveInputIdPrefixIntoString(array(get_class($this->model), 'textContent')), Element::resolveInputIdPrefixIntoString(array(get_class($this->model), 'htmlContent')), false);
$content = $view->render();
return $title . $content;
}
示例2: renderContent
protected function renderContent()
{
$this->resolveContentForFooter();
$this->resolveContentForMergeTags();
$content = ZurmoHtml::tag('div', array('id' => 'footer-preview-modal-content', 'class' => 'footer-preview-modal'), $this->placeholderContent);
return $content;
}
示例3: renderControlEditable
/**
* Render a hidden input, a text input with an auto-complete
* event, and a select button. These three items together
* form the Opportunity Editable Element
* @return The element's content as a string.
*/
protected function renderControlEditable()
{
$content = null;
$content .= ZurmoHtml::textField('stageToProbabilityMapping_notUsed', null, array('id' => $this->getEditableInputId(), 'style' => "display:none;"));
$fieldData = CustomFieldData::getByName('SalesStages');
if ($fieldData->serializedData != null) {
$values = unserialize($fieldData->serializedData);
if (!is_array($values)) {
$values = array();
}
} else {
$values = array();
}
$stagesToProbabilities = OpportunitiesModule::getStageToProbabilityMappingData();
foreach ($values as $value) {
if (isset($stagesToProbabilities[$value])) {
$probability = $stagesToProbabilities[$value];
} else {
$probability = 0;
}
$htmlOptions = array('name' => $this->getNameForInputField($value), 'value' => $probability);
$element = $this->form->textField($this->model, $this->attribute, $htmlOptions);
$element .= ZurmoHtml::tag('span', array(), $value);
$content .= ZurmoHtml::tag('div', array('class' => 'has-lang-label'), $element);
}
return $content;
}
示例4: resolveWrapperTdNonEditableByContent
protected function resolveWrapperTdNonEditableByContent($content, array $properties = array())
{
$this->resolveContentWhenColumnIsEmpty($content);
$content = parent::resolveWrapperTdNonEditableByContent($content, $properties);
$content .= ZurmoHtml::tag('td', $this->resolveNonEditableExpanderTdHtmlOptions(), '');
return $content;
}
示例5: renderLabel
/**
* Override to ensure label is pointing to the right input id
* @return A string containing the element's label
*/
protected function renderLabel()
{
if ($this->form === null) {
throw new NotImplementedException();
}
return ZurmoHtml::tag('h3', array(), Zurmo::t('ImportModule', 'Please select the module you would like to import to:'));
}
示例6: renderTabs
protected function renderTabs()
{
$content = ZurmoHtml::link(Zurmo::t('ZurmoModule', 'Library'), '#', array('class' => 'choose-tab active', 'data-view' => 'ImageModalSearchAndListView'));
$content .= ZurmoHtml::link(Zurmo::t('ZurmoModule', 'Upload'), '#', array('class' => 'upload-tab', 'data-view' => 'ImageFilesUploadView'));
$content .= ZurmoHtml::link(Zurmo::t('ZurmoModule', 'Import From Url'), '#', array('class' => 'upload-tab', 'data-view' => 'ImageFilesImportFromUrlView'));
return ZurmoHtml::tag('div', array('class' => 'image-tabs clearfix'), $content);
}
示例7: renderAfterFormLayout
protected function renderAfterFormLayout($form)
{
$title = '<h3>' . $this->getAfterFormLayoutTranslatedTitleContent() . '</h3>';
$element = new EditableDropDownCollectionElement($this->model, 'customFieldDataData', $form, array('specificValueFromDropDownAttributeName' => 'defaultValueOrder', 'baseLanguage' => Yii::app()->languageHelper->getBaseLanguage(), 'activeLanguagesData' => Yii::app()->languageHelper->getActiveLanguagesData(), 'labelsAttributeName' => 'customFieldDataLabels'));
$content = ZurmoHtml::tag('div', array('class' => 'left-column full-width'), $title . $element->render());
return $content;
}
示例8: resolveElementDuringFormLayoutRender
/**
* Override to change the editableTemplate to place the label above the input.
* @see DetailsView::resolveElementDuringFormLayoutRender()
*/
protected function resolveElementDuringFormLayoutRender(&$element)
{
if ($element->getAttribute() == 'name') {
$notification = ZurmoHtml::tag('span', array('class' => 'row-description'), Zurmo::t('MarketingListsModule', 'Name will be publicly viewable by Contacts/Leads to manage their subscriptions'));
$element->editableTemplate = '<th>{label}</th><td colspan="{colspan}">{content}' . $notification . '{error}</td>';
}
}
示例9: renderAfterFormLayout
protected function renderAfterFormLayout($form)
{
$content = ZurmoHtml::tag('h3', array(), Zurmo::t('ContactsModule', 'Contact Statuses'));
$element = new EditableDropDownCollectionElement($this->model, 'contactStatesData', $form, array('specificValueFromDropDownAttributeName' => 'startingStateOrder', 'baseLanguage' => Yii::app()->languageHelper->getBaseLanguage(), 'activeLanguagesData' => Yii::app()->languageHelper->getActiveLanguagesData(), 'labelsAttributeName' => 'contactStatesLabels'));
$content .= ZurmoHtml::tag('div', array('class' => 'left-column full-width'), $element->render());
return $content;
}
示例10: renderHtmlAndTextContentElement
protected function renderHtmlAndTextContentElement($model, $attribute, $form)
{
$this->registerContentTabsHeightScripts();
$params = array(EmailTemplateHtmlAndTextContentElement::SELECTIVE_TAB_LOAD_KEY => true);
$element = new EmailTemplateHtmlAndTextContentElement($model, $attribute, $form, $params);
return ZurmoHtml::tag('div', array('class' => 'email-template-combined-content'), $element->render());
}
示例11: renderToggleLinkContent
/**
* @return string
*/
public static function renderToggleLinkContent()
{
static::registerSlidingPanelsScript();
$content = ZurmoHtml::tag('span', array(), static::getSlideToSecondPanelLabel());
$content = ZurmoHtml::link($content, '#', array('id' => 'sliding-panel-toggle', 'class' => 'vertical-forward-pager slide-to-second-panel'));
return $content;
}
示例12: errorSummary
/**
* Override to handle relation model error summary information. This information needs to be parsed properly
* otherwise it will show up as 'Array' for the error text.
* @see CActiveForm::errorSummary()
*/
public function errorSummary($models, $header = null, $footer = null, $htmlOptions = array())
{
if (!$this->enableAjaxValidation && !$this->enableClientValidation) {
return ZurmoHtml::errorSummary($models, $header, $footer, $htmlOptions);
}
if (!isset($htmlOptions['id'])) {
$htmlOptions['id'] = $this->id . '_es_';
}
$html = ZurmoHtml::errorSummary($models, $header, $footer, $htmlOptions);
if ($html === '') {
if ($header === null) {
$header = '<p>' . Yii::t('yii', 'Please fix the following input errors:') . '</p>';
}
if (!isset($htmlOptions['class'])) {
$htmlOptions['class'] = ZurmoHtml::$errorSummaryCss;
}
if (isset($htmlOptions['style'])) {
$htmlOptions['style'] = rtrim($htmlOptions['style'], ';') . ';display:none';
} else {
$htmlOptions['style'] = 'display:none';
}
$html = ZurmoHtml::tag('div', $htmlOptions, $header . "\n<ul><li>dummy</li></ul>" . $footer);
}
$this->summaryID = $htmlOptions['id'];
return $html;
}
示例13: renderContent
protected function renderContent()
{
$homeUrl = Yii::app()->createUrl('home/default');
$content = '<div class="clearfix">';
$content .= '<a href="#" id="nav-trigger" title="Toggle Navigation">›</a>';
$content .= '<div id="corp-logo">';
if ($logoFileModelId = ZurmoConfigurationUtil::getByModuleName('ZurmoModule', 'logoFileModelId')) {
$logoFileModel = FileModel::getById($logoFileModelId);
$logoFileSrc = Yii::app()->getAssetManager()->getPublishedUrl(Yii::getPathOfAlias('application.runtime.uploads') . DIRECTORY_SEPARATOR . $logoFileModel->name);
} else {
$logoFileSrc = Yii::app()->themeManager->baseUrl . '/default/images/Zurmo_logo.png';
}
$logoHeight = ZurmoConfigurationFormAdapter::resolveLogoHeight();
$logoWidth = ZurmoConfigurationFormAdapter::resolveLogoWidth();
if (Yii::app()->userInterface->isMobile()) {
$content .= '<a href="' . $homeUrl . '"><img src="' . $logoFileSrc . '" alt="Zurmo Logo" /></a>';
//make sure width and height are NEVER defined
} else {
$content .= '<a href="' . $homeUrl . '"><img src="' . $logoFileSrc . '" alt="Zurmo Logo" height="' . $logoHeight . '" width="' . $logoWidth . '" /></a>';
}
if ($this->applicationName != null) {
$content .= ZurmoHtml::tag('span', array(), $this->applicationName);
}
$content .= '</div>';
if (!empty($this->userMenuItems) && !empty($this->settingsMenuItems)) {
$content .= '<div id="user-toolbar" class="clearfix">';
$content .= static::renderHeaderMenus($this->userMenuItems, $this->settingsMenuItems);
$content .= '</div>';
}
$content .= '</div>';
return $content;
}
示例14: renderAmountContent
/**
* Renders amount
* @return string
*/
protected function renderAmountContent()
{
$model = $this->model;
$amount = Yii::app()->numberFormatter->formatCurrency((double) $model->amount->value, $model->amount->currency->code);
$content = ZurmoHtml::tag('p', array('class' => static::DESCRIPTION_CLASS), Zurmo::t('OpportunitiesModule', 'Amount') . $this->overlayKeyValueSeparator . $amount);
return $content;
}
示例15: getLinkStringForActivityItem
public static function getLinkStringForActivityItem($model, $linkRoute, $moduleClassName)
{
$modelClassName = get_class($model);
$linkString = ActionSecurityUtil::resolveLinkToEditModelForCurrentUser(strval($model), $model, $moduleClassName, $linkRoute) . ' (' . $modelClassName . ')';
$text = ZurmoHtml::tag('div', array(), $linkString);
return $text;
}
开发者ID:KulturedKitsch,项目名称:kulturedkitsch.info,代码行数:7,代码来源:TaskActivityItemsListViewColumnAdapter.php