當前位置: 首頁>>代碼示例>>PHP>>正文


PHP JDocumentHtml::addScript方法代碼示例

本文整理匯總了PHP中JDocumentHtml::addScript方法的典型用法代碼示例。如果您正苦於以下問題:PHP JDocumentHtml::addScript方法的具體用法?PHP JDocumentHtml::addScript怎麽用?PHP JDocumentHtml::addScript使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在JDocumentHtml的用法示例。


在下文中一共展示了JDocumentHtml::addScript方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: prepareDocument

 /**
  * Prepare document
  */
 protected function prepareDocument()
 {
     //Escape strings for HTML output
     $this->pageclass_sfx = htmlspecialchars($this->params->get('pageclass_sfx'));
     // Prepare page heading
     $this->prepearePageHeading();
     // Prepare page heading
     $this->preparePageTitle();
     // Meta Description
     if ($this->params->get('menu-meta_description')) {
         $this->document->setDescription($this->params->get('menu-meta_description'));
     }
     // Meta keywords
     if ($this->params->get('menu-meta_keywords')) {
         $this->document->setMetaData('keywords', $this->params->get('menu-meta_keywords'));
     }
     if ($this->params->get('robots')) {
         $this->document->setMetaData('robots', $this->params->get('robots'));
     }
     // Scripts
     JHtml::_('behavior.tooltip');
     JHtml::_('Prism.ui.pnotify');
     JHtml::_('Prism.ui.joomlaHelper');
     $this->document->addScript('media/' . $this->option . '/js/site/' . JString::strtolower($this->getName()) . '.js');
 }
開發者ID:ITPrism,項目名稱:SocialCommunityDistribution,代碼行數:28,代碼來源:view.html.php

示例2: setDocument

 protected function setDocument()
 {
     // Add scripts
     JHtml::_('bootstrap.tooltip');
     JHtml::_('behavior.formvalidation');
     JHtml::_('formbehavior.chosen', 'select');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . $this->getName() . '.js');
 }
開發者ID:brenot,項目名稱:forumdesenvolvimento,代碼行數:8,代碼來源:view.html.php

示例3: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle($this->documentTitle);
     // Add scripts
     JHtml::_('behavior.tooltip');
     JHtml::_('behavior.formvalidation');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . String::strtolower($this->getName()) . '.js');
 }
開發者ID:bellodox,項目名稱:GamificationPlatform,代碼行數:13,代碼來源:view.html.php

示例4: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle(JText::_('COM_GAMIFICATION_TOOLS'));
     // Scripts
     JHtml::_('bootstrap.tooltip');
     JHtml::_('formbehavior.chosen', 'select');
     JHtml::_('Prism.ui.pnotify');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . strtolower($this->getName()) . '.js');
 }
開發者ID:ITPrism,項目名稱:GamificationDistribution,代碼行數:14,代碼來源:view.html.php

示例5: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle(JText::_('COM_EMAILTEMPLATES_IMPORT_MANAGER'));
     // Scripts
     JHtml::_('behavior.formvalidation');
     JHtml::_('bootstrap.tooltip');
     JHtml::_('Prism.ui.bootstrap2FileInput');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . JString::strtolower($this->getName()) . '.js');
 }
開發者ID:ITPrism,項目名稱:CrowdfundingDistribution,代碼行數:14,代碼來源:view.html.php

示例6: setDocument

 /**
  * Method to set up the document properties
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle($this->documentTitle);
     // Scripts
     JHtml::_('behavior.formvalidation');
     JHtml::_('behavior.tooltip');
     JHtml::_('formbehavior.chosen', 'select');
     $this->document->addScript(JURI::root() . 'media/' . $this->option . '/js/admin/' . Joomla\String\String::strtolower($this->getName()) . '.js');
 }
開發者ID:Eautentik,項目名稱:CrowdFunding,代碼行數:13,代碼來源:view.html.php

示例7: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle(JText::_('COM_VIRTUALCURRENCY_IMPORT_MANAGER'));
     $this->legend = JText::_("COM_VIRTUALCURRENCY_IMPORT_REAL_CURRENCY_DATA");
     // Scripts
     JHtml::_('behavior.formvalidation');
     JHtml::_('bootstrap.tooltip');
     JHtml::_('itprism.ui.bootstrap_fileuploadstyle');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . JString::strtolower($this->getName()) . '.js');
 }
開發者ID:bellodox,項目名稱:VirtualCurrency,代碼行數:15,代碼來源:view.html.php

示例8: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle(JText::_('COM_CROWDFUNDING_TOOLS'));
     // Scripts
     JHtml::_('bootstrap.tooltip');
     JHtml::_('formbehavior.chosen', 'select');
     JHtml::_('Prism.ui.pnotify');
     JHtml::_('Prism.ui.joomlaHelper');
     JHtml::_('Prism.ui.serializeJson');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . JString::strtolower($this->getName()) . '.js');
 }
開發者ID:ITPrism,項目名稱:CrowdfundingDistribution,代碼行數:16,代碼來源:view.html.php

示例9: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle($this->documentTitle);
     // Add scripts
     JHtml::_('bootstrap.tooltip');
     JHtml::_('behavior.keepalive');
     JHtml::_('behavior.formvalidation');
     $d3Cdn = (bool) $this->params->get('d3_cdn', true);
     JHtml::_('Prism.ui.d3', $d3Cdn);
     $js = '
         cfProjectId = ' . $this->item->id . ';
     ';
     $this->document->addScriptDeclaration($js);
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . JString::strtolower($this->getName()) . '.js');
 }
開發者ID:ITPrism,項目名稱:CrowdfundingDistribution,代碼行數:20,代碼來源:view.html.php

示例10: prepareCommentsScreen

 protected function prepareCommentsScreen()
 {
     $this->commentsEnabled = $this->params->get('comments_enabled', 1);
     // Initialize default comments functionality.
     if ($this->commentsEnabled) {
         $model = JModelLegacy::getInstance('Comments', 'CrowdfundingModel', $config = array('ignore_request' => false));
         $this->items = $model->getItems();
         $this->form = $model->getForm();
         $this->userId = JFactory::getUser()->get('id');
         $this->isOwner = $this->userId === $this->item->user_id;
         // Get users IDs
         $usersIds = Prism\Utilities\ArrayHelper::getIds($this->items, 'user_id');
         // Prepare social integration.
         $this->socialProfiles = CrowdfundingHelper::prepareIntegration($this->params->get('integration_social_platform'), $usersIds);
         // Scripts
         JHtml::_('behavior.keepalive');
         JHtml::_('behavior.formvalidation');
         JHtml::_('prism.ui.pnotify');
         JHtml::_('Prism.ui.joomlaHelper');
         $this->document->addScript('media/' . $this->option . '/js/site/comments.js');
     }
     // Trigger comments plugins.
     $dispatcher = JEventDispatcher::getInstance();
     $results = $dispatcher->trigger('onContentAfterDisplay', array('com_crowdfunding.comments', &$this->item, &$this->params));
     $this->onCommentAfterDisplay = trim(implode("\n", $results));
 }
開發者ID:ITPrism,項目名稱:CrowdfundingDistribution,代碼行數:26,代碼來源:view.html.php

示例11: prepareDocument

 /**
  * Prepare the document
  */
 protected function prepareDocument()
 {
     // Escape strings for HTML output
     $this->pageclass_sfx = htmlspecialchars($this->params->get('pageclass_sfx'));
     // Prepare page heading
     $this->preparePageHeading();
     // Prepare page heading
     $this->preparePageTitle();
     if ($this->params->get('menu-meta_description')) {
         $this->document->setDescription($this->params->get('menu-meta_description'));
     } else {
         $this->document->setDescription($this->item->short_desc);
     }
     if ($this->params->get('menu-meta_keywords')) {
         $this->document->setMetadata('keywords', $this->params->get('menu-meta_keywords'));
     }
     if ($this->params->get('robots')) {
         $this->document->setMetadata('robots', $this->params->get('robots'));
     }
     // Breadcrumb
     $pathway = $this->app->getPathWay();
     $currentBreadcrumb = JHtmlString::truncate($this->item->title, 16);
     $pathway->addItem($currentBreadcrumb, '');
     // Scripts
     JHtml::_('bootstrap.framework');
     $this->document->addScript('media/' . $this->option . '/js/site/backing.js');
 }
開發者ID:phpsource,項目名稱:CrowdFunding,代碼行數:30,代碼來源:view.html.php

示例12: prepareCommentsScreen

 protected function prepareCommentsScreen()
 {
     $this->commentsEnabled = $this->params->get("comments_enabled", 1);
     // Initialize default comments functionality.
     if ($this->commentsEnabled) {
         $model = JModelLegacy::getInstance("Comments", "CrowdFundingModel", $config = array('ignore_request' => false));
         $this->items = $model->getItems();
         $this->form = $model->getForm();
         $this->userId = JFactory::getUser()->get("id");
         $this->isOwner = $this->userId != $this->item->user_id ? false : true;
         // Get users IDs
         $usersIds = array();
         foreach ($this->items as $item) {
             $usersIds[] = $item->user_id;
         }
         // Prepare integration. Load avatars and profiles.
         $this->prepareIntegration($usersIds, $this->params);
         // Scripts
         JHtml::_('behavior.keepalive');
         JHtml::_('behavior.formvalidation');
         JHtml::_('itprism.ui.pnotify');
         JHtml::_("itprism.ui.joomla_helper");
         $this->document->addScript('media/' . $this->option . '/js/site/comments.js');
     }
     // Trigger comments plugins.
     $dispatcher = JEventDispatcher::getInstance();
     $results = $dispatcher->trigger('onContentAfterDisplay', array('com_crowdfunding.comments', &$this->item, &$this->params));
     $this->onCommentAfterDisplay = trim(implode("\n", $results));
 }
開發者ID:phpsource,項目名稱:CrowdFunding,代碼行數:29,代碼來源:view.html.php

示例13: prepareDocument

 /**
  * Prepare document
  */
 protected function prepareDocument()
 {
     //Escape strings for HTML output
     $this->pageclass_sfx = htmlspecialchars($this->params->get('pageclass_sfx'));
     // Prepare page heading
     $this->preparePageHeading();
     // Prepare page heading
     $this->preparePageTitle();
     // Meta Description
     if ($this->params->get('menu-meta_description')) {
         $this->document->setDescription($this->params->get('menu-meta_description'));
     }
     // Meta keywords
     if ($this->params->get('menu-meta_keywords')) {
         $this->document->setMetadata('keywords', $this->params->get('menu-meta_keywords'));
     }
     if ($this->params->get('robots')) {
         $this->document->setMetadata('robots', $this->params->get('robots'));
     }
     // Include the translation of the confirmation question.
     JText::script('COM_IDENTITYPROOF_DELETE_QUESTION');
     JHtml::_('bootstrap.tooltip');
     JHtml::_('behavior.core');
     JHtml::_('itprism.ui.bootstrap_fileuploadstyle');
     JHtml::_('itprism.ui.bootstrap_modal');
     JHtml::_("itprism.ui.pnotify");
     JHtml::_('itprism.ui.joomla_helper');
     $this->document->addScript('media/' . $this->option . '/js/site/proof.js');
 }
開發者ID:xop32,項目名稱:Proof-of-Identity,代碼行數:32,代碼來源:view.html.php

示例14: prepareDocument

 /**
  * Prepare document
  */
 protected function prepareDocument()
 {
     //Escape strings for HTML output
     $this->pageclass_sfx = htmlspecialchars($this->params->get('pageclass_sfx'));
     // Prepare page heading
     $this->preparePageHeading();
     // Prepare page heading
     $this->preparePageTitle();
     // Meta Description
     if ($this->params->get('menu-meta_description')) {
         $this->document->setDescription($this->params->get('menu-meta_description'));
     }
     // Meta keywords
     if ($this->params->get('menu-meta_keywords')) {
         $this->document->setMetaData('keywords', $this->params->get('menu-meta_keywords'));
     }
     if ($this->params->get('robots')) {
         $this->document->setMetaData('robots', $this->params->get('robots'));
     }
     // Scripts
     JHtml::_('bootstrap.tooltip');
     JHtml::_('Prism.ui.pnotify');
     JHtml::_('Prism.ui.joomlaHelper');
     $this->document->addScript('media/com_crowdfunding/js/site/reward_state.js');
 }
開發者ID:sis-direct,項目名稱:CrowdFunding,代碼行數:28,代碼來源:view.html.php

示例15: setDocument

 /**
  * Method to set up the document properties
  *
  * @return void
  */
 protected function setDocument()
 {
     $this->document->setTitle(JText::_('COM_CROWDFUNDING_IMPORT_MANAGER'));
     // Scripts
     JHtml::_('behavior.formvalidation');
     JHtml::_('bootstrap.tooltip');
     JHtml::_('prism.ui.bootstrapFileUploadStyle');
     $this->document->addScript('../media/' . $this->option . '/js/admin/' . Joomla\String\String::strtolower($this->getName()) . '.js');
 }
開發者ID:bharatthakkar,項目名稱:CrowdFunding,代碼行數:14,代碼來源:view.html.php


注:本文中的JDocumentHtml::addScript方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。