当前位置: 首页>>代码示例>>PHP>>正文


PHP Template::put_all方法代码示例

本文整理汇总了PHP中Template::put_all方法的典型用法代码示例。如果您正苦于以下问题:PHP Template::put_all方法的具体用法?PHP Template::put_all怎么用?PHP Template::put_all使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Template的用法示例。


在下文中一共展示了Template::put_all方法的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 public function __construct($step_number, $step_title, Template $view)
 {
     $this->load_language_resources();
     $this->init_response($step_number, $view);
     $env = new InstallDisplayGraphicalEnvironment();
     $this->add_language_bar();
     $this->init_steps();
     $this->update_progress_bar();
     $this->full_view->put_all(array('RESTART' => InstallUrlBuilder::welcome()->rel(), 'STEP_TITLE' => $step_title, 'C_HAS_PREVIOUS_STEP' => false, 'C_HAS_NEXT_STEP' => false, 'L_XML_LANGUAGE' => LangLoader::get_message('xml_lang', 'main'), 'PROGRESSION' => floor(100 * $this->current_step / ($this->nb_steps - 1)), 'PHPBOOST_VERSION' => GeneralConfig::load()->get_phpboost_major_version()));
     parent::__construct($env, $this->full_view);
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:11,代码来源:InstallDisplayResponse.class.php

示例2: __construct

 public function __construct($step_number, $step_title, Template $view)
 {
     $this->load_language_resources();
     $this->init_response($step_number, $view);
     $env = new UpdateDisplayGraphicalEnvironment();
     $this->add_language_bar();
     $this->init_steps();
     $this->update_progress_bar();
     $this->full_view->put_all(array('RESTART' => UpdateUrlBuilder::introduction()->rel(), 'STEP_TITLE' => $step_title, 'C_HAS_PREVIOUS_STEP' => false, 'C_HAS_NEXT_STEP' => false, 'L_XML_LANGUAGE' => LangLoader::get_message('xml_lang', 'main'), 'PROGRESSION' => floor(100 * $this->current_step / $this->nb_steps)));
     parent::__construct($env, $this->full_view);
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:11,代码来源:UpdateDisplayResponse.class.php

示例3: build_view

 private function build_view()
 {
     $this->view = new FileTemplate('update/server-config.tpl');
     $this->view->put_all(array('MIN_PHP_VERSION' => ServerConfiguration::MIN_PHP_VERSION, 'PHP_VERSION_OK' => $this->server_conf->is_php_compatible(), 'HAS_GD_LIBRARY' => $this->server_conf->has_gd_library()));
     if (!PHPBoostFoldersPermissions::validate()) {
         $this->view->put('ERROR', $this->lang['folders.chmod.error']);
     }
     try {
         $this->view->put('URL_REWRITING_KNOWN', true);
         $this->view->put('URL_REWRITING_AVAILABLE', $this->server_conf->has_url_rewriting());
     } catch (UnsupportedOperationException $ex) {
         $this->view->put('URL_REWRITING_KNOWN', false);
     }
     $this->check_folders_permissions();
     $this->view->put('CONTINUE_FORM', $this->form->display());
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:16,代码来源:UpdateServerConfigController.class.php

示例4: add_navigation

 private function add_navigation(Template $view)
 {
     $form = new HTMLForm('preambleForm', UpdateUrlBuilder::server_configuration()->rel(), false);
     $action_fieldset = new FormFieldsetSubmit('actions');
     $next = new FormButtonSubmitCssImg($this->lang['step.next'], 'fa fa-arrow-right', 'introduction');
     $action_fieldset->add_element($next);
     $form->add_fieldset($action_fieldset);
     $view->put_all(array('C_PUT_UNDER_MAINTENANCE' => !MaintenanceConfig::load()->is_under_maintenance(), 'SERVER_FORM' => $form->display()));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:9,代码来源:UpdateIntroductionController.class.php

示例5: display

 /**
  * @desc Displays the bread crumb.
  */
 public function display(Template $tpl)
 {
     if (empty($this->array_links)) {
         $this->add($this->get_page_title(), REWRITED_SCRIPT);
     }
     $tpl->put_all(array('START_PAGE' => TPL_PATH_TO_ROOT . '/', 'L_INDEX' => LangLoader::get_message('home', 'main')));
     $output = array_slice($this->array_links, -1, 1);
     foreach ($this->array_links as $key => $array) {
         $tpl->assign_block_vars('link_bread_crumb', array('C_CURRENT' => $output[0] == $array, 'URL' => $array[1], 'TITLE' => $array[0]));
     }
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:14,代码来源:BreadCrumb.class.php

示例6: display_counter

 protected function display_counter(Template $template)
 {
     //If the counter is to be displayed, we display it
     if (GraphicalEnvironmentConfig::load()->is_visit_counter_enabled()) {
         $compteur = PersistenceContext::get_querier()->select_single_row(DB_TABLE_VISIT_COUNTER, array('ip AS nbr_ip', 'total'), 'WHERE id = 1');
         $compteur_total = !empty($compteur['nbr_ip']) ? $compteur['nbr_ip'] : '1';
         $compteur_day = !empty($compteur['total']) ? $compteur['total'] : '1';
         $template->put_all(array('L_VISIT' => self::$main_lang['guest_s'], 'L_TODAY' => LangLoader::get_message('today', 'date-common'), 'C_COMPTEUR' => true, 'COMPTEUR_TOTAL' => $compteur_total, 'COMPTEUR_DAY' => $compteur_day));
     }
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:10,代码来源:SiteDisplayGraphicalEnvironment.class.php

示例7: assign_common_template_variables

 /**
  * @desc Assign default tpl vars
  * @access protected
  * @param Template $template the template on which we gonna assign vars
  */
 protected function assign_common_template_variables(Template $template)
 {
     $template->put_all(array('C_VERTICAL_BLOCK' => $this->get_block() == Menu::BLOCK_POSITION__LEFT || $this->get_block() == Menu::BLOCK_POSITION__RIGHT, 'C_HIDDEN_WITH_SMALL_SCREENS' => $this->hidden_with_small_screens));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:9,代码来源:Menu.class.php

示例8: assign_common_template_variables

 protected function assign_common_template_variables(Template $template)
 {
     $has_js_validations = false;
     $js_tpl = new FileTemplate('framework/builder/form/AddFieldJS.tpl');
     foreach ($this->get_related_fields() as $field) {
         $js_tpl->assign_block_vars('related_field', array('ID' => $field));
         $has_js_validations = true;
     }
     foreach ($this->events as $event => $handler) {
         $js_tpl->assign_block_vars('event_handler', array('EVENT' => $event, 'HANDLER' => $handler));
         $has_js_validations = true;
     }
     foreach ($this->get_js_validations() as $constraint) {
         $js_tpl->assign_block_vars('constraint', array('CONSTRAINT' => $constraint));
         $has_js_validations = true;
     }
     $js_tpl->put_all(array('C_DISABLED' => $this->is_disabled(), 'C_HAS_CONSTRAINTS' => $this->has_constraints(), 'ID' => $this->get_id(), 'HTML_ID' => $this->get_html_id(), 'JS_SPECIALIZATION_CODE' => $this->get_js_specialization_code(), 'FORM_ID' => $this->form_id, 'FIELDSET_ID' => $this->fieldset_id));
     $template->put('ADD_FIELD_JS', $js_tpl);
     $description = $this->get_description();
     $template->put_all(array('ID' => $this->get_id(), 'HTML_ID' => $this->get_html_id(), 'NAME' => $this->get_html_id(), 'LABEL' => $this->get_label(), 'DESCRIPTION' => $description, 'C_DESCRIPTION' => !empty($description), 'C_REQUIRED' => $this->is_required(), 'C_REQUIRED_AND_HAS_VALUE' => $this->is_required() && (!empty($this->value) || $this->value == '0'), 'VALUE' => $this->get_value(), 'C_HAS_CONSTRAINTS' => $this->has_constraints(), 'CLASS' => $this->get_css_class(), 'FIELD_CLASS' => $this->get_css_field_class(), 'C_HAS_FIELD_CLASS' => $this->get_css_field_class() != '', 'FORM_FIELD_CLASS' => $this->get_css_form_field_class(), 'C_HAS_FORM_FIELD_CLASS' => $this->get_css_form_field_class() != '', 'FORM_ID' => $this->form_id, 'FIELDSET_ID' => $this->fieldset_id, 'C_HAS_LABEL' => !empty($description) || $this->get_label() != '', 'C_DISABLED' => $this->is_disabled(), 'C_READONLY' => $this->is_readonly(), 'C_HIDDEN' => $this->is_hidden(), 'C_PATTERN' => $this->has_pattern(), 'PATTERN' => $this->pattern, 'C_PLACEHOLDER' => $this->has_placeholder(), 'PLACEHOLDER' => $this->placeholder));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:21,代码来源:AbstractFormField.class.php

示例9: set_title

 public function set_title($title)
 {
     $this->full_view->put_all(array('TITLE' => $title));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:4,代码来源:AdminMenuDisplayResponse.class.php

示例10: generate_stats

 private function generate_stats()
 {
     $end = $this->get_first_row_index() + $this->get_nb_rows_per_page();
     $elements = StringVars::replace_vars(LangLoader::get_message('table_footer_stats', 'common'), array('start' => $this->get_first_row_index() + 1, 'end' => $end > $this->nb_rows || $this->get_nb_rows_per_page() == HTMLTableModel::NO_PAGINATION ? $this->nb_rows : $end, 'total' => $this->nb_rows));
     $this->tpl->put_all(array('NUMBER_OF_ELEMENTS' => $elements));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:6,代码来源:HTMLTable.class.php

示例11: assign_textarea_template_variables

 private function assign_textarea_template_variables(Template $template)
 {
     $template->put_all(array('ROWS' => $this->rows, 'COLS' => $this->cols));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:4,代码来源:FormFieldMultiLineTextEditor.class.php

示例12: assign_editor

 private function assign_editor(Template $template)
 {
     $editor = $this->formatter->get_editor();
     $editor->set_identifier($this->get_html_id());
     $template->put_all(array('C_EDITOR_ENABLED' => true, 'EDITOR' => $editor->display(), 'VALUE' => $this->get_raw_value(), 'PREVIEW_BUTTON' => $this->get_preview_button_code()));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:6,代码来源:FormFieldRichTextEditor.class.php

示例13: assign_template_fields

 protected function assign_template_fields(Template $template)
 {
     $js_tpl = new FileTemplate('framework/builder/form/AddFieldsetJS.tpl');
     $js_tpl->put_all(array('ID' => $this->id, 'HTML_ID' => $this->get_html_id(), 'C_DISABLED' => $this->disabled, 'FORM_ID' => $this->form_id));
     $template->put('ADD_FIELDSET_JS', $js_tpl);
     $template->put_all(array('C_DESCRIPTION' => !empty($this->description), 'DESCRIPTION' => $this->description, 'ID' => $this->id, 'HTML_ID' => $this->get_html_id(), 'C_DISABLED' => $this->disabled, 'CSS_CLASS' => $this->css_class, 'FORM_ID' => $this->form_id));
     foreach ($this->elements as $element) {
         $template->assign_block_vars('elements', array(), array('ELEMENT' => $element->display()));
     }
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:10,代码来源:AbstractFormFieldset.class.php

示例14: assign_positions_conditions

 /**
  * @desc Assigns the positions conditions for different printing modes
  * @param Template $template the template to use
  * @param int $position the menu position
  */
 public static function assign_positions_conditions($template, $position)
 {
     $vertical_position = in_array($position, array(Menu::BLOCK_POSITION__LEFT, Menu::BLOCK_POSITION__RIGHT));
     $template->put_all(array('C_HEADER' => $position == Menu::BLOCK_POSITION__HEADER, 'C_SUBHEADER' => $position == Menu::BLOCK_POSITION__SUB_HEADER, 'C_TOP_CENTRAL' => $position == Menu::BLOCK_POSITION__TOP_CENTRAL, 'C_BOTTOM_CENTRAL' => $position == Menu::BLOCK_POSITION__BOTTOM_CENTRAL, 'C_TOP_FOOTER' => $position == Menu::BLOCK_POSITION__TOP_FOOTER, 'C_FOOTER' => $position == Menu::BLOCK_POSITION__FOOTER, 'C_LEFT' => $position == Menu::BLOCK_POSITION__LEFT, 'C_RIGHT' => $position == Menu::BLOCK_POSITION__RIGHT, 'C_VERTICAL' => $vertical_position, 'C_HORIZONTAL' => !$vertical_position));
 }
开发者ID:AroundPBT,项目名称:PHPBoost,代码行数:10,代码来源:MenuService.class.php


注:本文中的Template::put_all方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。