本文整理汇总了PHP中JHtml::script方法的典型用法代码示例。如果您正苦于以下问题:PHP JHtml::script方法的具体用法?PHP JHtml::script怎么用?PHP JHtml::script使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类JHtml
的用法示例。
在下文中一共展示了JHtml::script方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: display
/**
* Display the view
*/
function display()
{
$document =& JFactory::getDocument();
$document->setTitle(JText::_('NEW_DM_TASK'));
JHtml::script('dmtaskForm.js', 'media/com_dbconnect/js/');
//TOOLBAR, CSS
JHtml::stylesheet('main.css', 'media/com_dbconnect/css/');
if (JPATH_BASE == JPATH_ADMINISTRATOR) {
JHtml::stylesheet('admin.css', 'media/com_dbconnect/css/');
JToolBarHelper::title(JText::_('NEW_DM_TASK'), 'dbconnect');
}
//
JHTML::_('behavior.modal');
$this->unidbModel = $this->getModel('unidb', 'unidbModel');
$this->assignRef('columns', $this->unidbModel->getColumns($this->connection->table));
if (isset($this->dmTask)) {
$document->setTitle(JText::_('EDIT_DM_TASK'));
$columnsXml = simplexml_load_string($this->dmTask->columns);
//upravujeme stávající úlohu - máme zadané xml s daty o sloupcích
$this->assign('editTask', true);
$columnsArr = array();
foreach ($columnsXml as $column) {
$columnName = (string) $column['name'];
$columnsArr[$columnName] = array('use' => (string) $column['use'], 'type' => (string) $column['type']);
}
$this->assignRef('columnsData', $columnsArr);
}
//DEVNOTE:call parent display
parent::display();
}
示例2: getInput
function getInput($name, $id, $value, $params)
{
$this->name = $name;
$this->id = $id;
$this->value = $value;
$this->params = $params;
JHtml::stylesheet('nnframework/colorpicker.min.css', false, true);
JHtml::script('nnframework/colorpicker/color_functions.js', false, true);
JHtml::script('nnframework/colorpicker/js_color_picker_v2.js', false, true);
$this->value = strtoupper(preg_replace('#[^a-z0-9]#si', '', $this->value));
$color = $this->value;
if (!$color) {
$color = 'DDDDDD';
}
$html = array();
if ($this->def('inlist', 0) && $this->def('action')) {
$html[] = '<input onclick="showColorPicker(this,this,\'' . addslashes($this->def('action')) . '\')" style="background-color:#' . $color . ';" type="text" name="' . $this->name . '" id="' . $this->name . $this->id . '" value="' . $this->value . '" class="nn_color nn_color_list" maxlength="6" size="1" />';
} else {
$html[] = '<fieldset id="' . $this->id . '" class="radio">';
$html[] = '<label class="radio" for="' . $this->id . '" style="width:auto;min-width:0;padding-right:0;"># </label>';
$html[] = '<input onclick="showColorPicker(this,this)" onchange="this.style.backgroundColor=\'#\'+this.value" style="background-color:#' . $color . ';" type="text" name="' . $this->name . '" id="' . $this->id . '" value="' . $this->value . '" class="nn_color" maxlength="6" size="8" />';
$html[] = '</fieldset>';
}
return implode('', $html);
}
示例3: image_compareYTShortcode
function image_compareYTShortcode($atts = null, $content = null)
{
$atts = ytshortcode_atts(array('before_image' => '', 'after_image' => '', 'orientation' => '', 'before_text' => 'Original', 'after_text' => 'Modified', 'class' => ''), $atts, 'image_compare');
// Unique Id
$id = uniqid("ytic") . rand() . time();
if (yt_image_media($atts['before_image']) && yt_image_media($atts['after_image'])) {
$orientation = $atts['orientation'] == 'horizontal' ? 'data-orientation="horizontal"' : '';
$css = '#' . $id . ' .twentytwenty-before-label:before {content: "' . $atts['before_text'] . '"}';
$css .= '#' . $id . ' .twentytwenty-after-label:before {content: "' . $atts['after_text'] . '"}';
// Css Adding in Head
JHtml::stylesheet(JUri::base() . "plugins/system/ytshortcodes/shortcodes/image_compare/css/image_compare.css", 'text/css');
// JavaScipt additon in Head
JHtml::_('jquery.framework');
JHtml::script(JUri::base() . "plugins/system/ytshortcodes/assets/js/jquery.twentytwenty.js");
JHtml::script(JUri::base() . "plugins/system/ytshortcodes/assets/js/jquery.event.move.js");
// OUtput Structure in here
$return = '
<div id="' . $id . '" class="twentytwenty-container' . trim($atts['class']) . '" data-orientation="horizontal">
<img src="' . yt_image_media($atts['before_image']) . '" alt="' . $atts['before_text'] . '">
<img src="' . yt_image_media($atts['after_image']) . '" alt="' . $atts['before_text'] . '">
</div>';
$js = 'jQuery(window).load(function(){
jQuery("#' . $id . '").twentytwenty({orientation: \'' . $atts['orientation'] . '\'});
});';
$doc = JFactory::getDocument();
$doc->addStyleDeclaration($css);
$doc->addScriptDeclaration($js);
} else {
$return = yt_alert_box('You can compare two images by using this shortcode', 'warning');
}
return $return;
}
示例4: getMessage
function getMessage($element = '', $xml = '', $version = '', $type = 'system', $admin = 1)
{
if (!$element) {
return '';
}
$alias = preg_replace('#[^a-z]#', '', strtolower($element));
if ($xml) {
$xml = JApplicationHelper::parseXMLInstallFile(JPATH_SITE . '/' . $xml);
if ($xml && isset($xml['version'])) {
$version = $xml['version'];
}
}
if (!$version) {
$version = self::getXMLVersion($element, $type, $admin);
}
if (!$version) {
return '';
}
JHtml::_('jquery.framework');
JHtml::script('nnframework/script.min.js', false, true);
$url = 'download.nonumber.nl/extensions.php?j=3&e=' . $alias;
$script = "\n\t\t\tjQuery(document).ready(function() {\n\t\t\t\tnnScripts.loadajax(\n\t\t\t\t\t'" . $url . "',\n\t\t\t\t\t'nnScripts.displayVersion( data, \"" . $alias . "\", \"" . str_replace(array('FREE', 'PRO'), '', $version) . "\" )',\n\t\t\t\t\t'nnScripts.displayVersion( \"\" )'\n\t\t\t\t);\n\t\t\t});\n\t\t";
JFactory::getDocument()->addScriptDeclaration($script);
return '<div class="alert alert-error" style="display:none;" id="nonumber_version_' . $alias . '">' . $this->getMessageText($alias, $version) . '</div>';
}
示例5: display
public function display($tpl = null)
{
// get model and update context with current
$model =& JModel::getInstance('urls', 'Sh404sefModel');
$context = $model->setContext($this->_context . '.' . $this->getLayout());
// store it
$model =& $this->setModel($model, true);
// read data from model
$list =& $model->getList((object) array('layout' => $this->getLayout(), 'getPageId' => true));
// and push it into the view for display
$this->assign('items', $list);
$this->assign('itemCount', count($this->items));
$this->assign('pagination', $model->getPagination((object) array('layout' => $this->getLayout(), 'getPageId' => true)));
$options = $model->getDisplayOptions();
$this->assign('options', $options);
$this->assign('optionsSelect', $this->_makeOptionsSelect($options));
$this->assign('helpMessage', JText16::_('COM_SH404SEF_PAGEID_HELP'));
// add behaviors and styles as needed
$modalSelector = 'a.modalediturl';
$js = '\\function(){shAlreadySqueezed = false;if(parent.shReloadModal) {parent.window.location=\'' . $this->defaultRedirectUrl . '\';parent.shReloadModal=true}}';
$params = array('overlayOpacity' => 0, 'classWindow' => 'sh404sef-popup', 'classOverlay' => 'sh404sef-popup', 'onClose' => $js);
Sh404sefHelperHtml::modal($modalSelector, $params);
// build the toolbar
$toolbarMethod = '_makeToolbar' . ucfirst($this->getLayout());
if (is_callable(array($this, $toolbarMethod))) {
$this->{$toolbarMethod}($params);
}
// add our own css
JHtml::styleSheet('list.css', Sh404sefHelperGeneral::getComponentUrl() . '/assets/css/');
// link to custom javascript
JHtml::script('list.js', Sh404sefHelperGeneral::getComponentUrl() . '/assets/js/');
JHtml::script('metas.js', Sh404sefHelperGeneral::getComponentUrl() . '/assets/js/');
// now display normally
parent::display($tpl);
}
示例6: notificationYTShortcode
function notificationYTShortcode($atts = null, $content = null)
{
$atts = ytshortcode_atts(array('effect' => 1, 'button_text' => 'Open notification', 'button_class' => '', 'close_button' => '', 'title' => 'notification Title', 'title_background' => 'rgba(0,0,0,0.1)', 'title_color' => '#222222', 'background' => '#ffffff', 'color' => '#666666', 'border' => 'none', 'shadow' => '0 solid #000000', 'width' => '640px', 'height' => 'auto', 'overlay_background' => '#000', 'class' => ''), $atts, 'notification');
$id = uniqid('ytmodal_') . rand() . time();
$id_over = uniqid() . rand() . time();
JHtml::stylesheet(JUri::base() . "plugins/system/ytshortcodes/shortcodes/notification/css/notification.css", 'text/css');
JHtml::_('jquery.framework');
JHtml::script(JUri::base() . "plugins/system/ytshortcodes/shortcodes/notification/js/notification.js");
$css = '
#' . $id . ' .yt-modal-content-wrapper { height: ' . $atts['height'] . '; width: ' . $atts['width'] . '; background: ' . $atts['background'] . '; color: ' . $atts['color'] . '; border: ' . $atts['border'] . '; box-shadow: ' . $atts['shadow'] . '; }
#' . $id . ' .yt-modal-title-wrapper { background: ' . $atts['title_background'] . '; }
#' . $id . ' .yt-modal-title-wrapper h3 { color: ' . $atts['title_color'] . '; }
';
$doc = JFactory::getDocument();
$doc->addStyleDeclaration($css);
$overlay_style = 'style=" background-color: ' . $atts['overlay_background'] . ';"';
$close_button = $atts['close_button'] === 'yes' ? '<a href="javascript:void(0);" class="yt-modal-close"><i class="fa fa-remove"></i></a>' : '';
$return = '<div class="yt-modal-wrapper">';
$return .= '<a href="javascript:void(0);" class="yt-modal-trigger ' . $atts['button_class'] . '" data-modal="' . $id . '">' . $atts['button_text'] . '</a>';
$return .= '<div class="yt-modal yt-modal-effect-' . $atts['effect'] . '" id="' . $id . '">
<div class="yt-modal-content-wrapper">';
$return .= '<div class="yt-modal-title-wrapper">';
$return .= '<h3>' . $atts['title'] . '</h3>';
$return .= $close_button;
$return .= '</div>';
$return .= '<div class="yt-content">';
$return .= parse_shortcode(str_replace(array("<br/>", "<br />", "<p></p>"), " ", $content));
$return .= '</div>
</div>
</div>
<div class="yt-modal-overlay ' . $id . '" ' . $overlay_style . '></div>';
$return .= '</div>';
return $return;
}
示例7: getMessage
function getMessage($element = '', $xml = '', $version = '', $type = 'system', $admin = 1)
{
if (!$element) {
return '';
}
$alias = preg_replace('#[^a-z]#', '', strtolower($element));
if ($xml) {
$xml = JApplicationHelper::parseXMLInstallFile(JPATH_SITE . '/' . $xml);
if ($xml && isset($xml['version'])) {
$version = $xml['version'];
}
}
if (!$version) {
$version = self::getXMLVersion($element, $type, $admin);
}
if (!$version) {
return '';
}
JHtml::_('behavior.mootools');
JHtml::script('nnframework/script.min.js', false, true);
$url = 'download.nonumber.nl/extensions.php?j=25&e=' . $alias;
$script = "\n\t\t\twindow.addEvent( 'domready', function() {\n\t\t\t\tnnScripts.loadajax(\n\t\t\t\t\t'" . $url . "',\n\t\t\t\t\t'nnScripts.displayVersion( data, \"" . $alias . "\", \"" . str_replace(array('FREE', 'PRO'), '', $version) . "\" )',\n\t\t\t\t\t'nnScripts.displayVersion( \"\" )'\n\t\t\t\t);\n\t\t\t});\n\t\t";
JFactory::getDocument()->addScriptDeclaration($script);
return $this->getMessageText($alias, $version);
}
示例8: display
public function display($tpl = null)
{
// get model and update context with current
$model =& $this->getModel();
$context = $model->setContext($this->_context . '.' . $this->getLayout());
// read data from model
$list =& $model->getList((object) array('layout' => $this->getLayout()));
// and push it into the view for display
$this->assign('items', $list);
$this->assign('itemCount', count($this->items));
$this->assign('pagination', $model->getPagination());
$options = $model->getDisplayOptions();
$this->assign('options', $options);
$this->assign('optionsSelect', $this->_makeOptionsSelect($options));
$this->assign('helpMessage', JText::_('COM_SH404SEF_ALIASES_HELP_NEW_ALIAS'));
// add behaviors and styles as needed
$modalSelector = 'a.modalediturl';
$js = '\\function(){window.parent.shAlreadySqueezed = false;if(window.parent.shReloadModal) {parent.window.location=\'' . $this->defaultRedirectUrl . '\';window.parent.shReloadModal=true}}';
$params = array('overlayOpacity' => 0, 'classWindow' => 'sh404sef-popup', 'classOverlay' => 'sh404sef-popup', 'onClose' => $js);
Sh404sefHelperHtml::modal($modalSelector, $params);
// build the toolbar
$toolBar = $this->_makeToolbar();
// insert needed css files
$this->_addCss();
// link to custom javascript
JHtml::script('list.js', Sh404sefHelperGeneral::getComponentUrl() . '/assets/js/');
// now display normally
parent::display($tpl);
}
示例9: display
public function display($tpl = null)
{
// get model and update context with current
$model =& $this->getModel();
$context = $model->updateContext($this->_context . '.' . $this->getLayout());
// get url id
$notFoundUrlId = JRequest::getInt('notfound_url_id');
// read url data from model
$url =& $model->getUrl($notFoundUrlId);
// and push url into the template for display
$this->assign('url', $url);
// build the toolbar
$toolBar = $this->_makeToolbar();
$this->assignRef('toolbar', $toolBar);
// add title.
$this->assign('toolbarTitle', Sh404sefHelperGeneral::makeToolbarTitle(JText16::_('COM_SH404SEF_NOT_FOUND_ENTER_REDIRECT'), $icon = 'addedit.png', $class = 'header'));
// insert needed css files
$this->_addCss();
// link to custom javascript
JHtml::script('edit.js', Sh404sefHelperGeneral::getComponentUrl() . '/assets/js/');
// add domready event
$document =& JFactory::getDocument();
// add tooltips
JHTML::_('behavior.tooltip');
// now display normally
parent::display($tpl);
}
示例10: getInput
protected function getInput()
{
if (!JevJoomlaVersion::isCompatible("3.4")) {
return "";
}
JLoader::register('JEVHelper', JPATH_SITE . "/components/com_jevents/libraries/helper.php");
JEVHelper::ConditionalFields($this->element, $this->form->getName());
$layouttype = $this->getAttribute("layouttype");
$target = $this->getAttribute("target");
$csstarget = $this->getAttribute("csstarget");
JHtml::script("https://www.jevents.net/jevlayouts/LatestEvents.js");
$html = "<script>jQuery(document).ready(function (\$){loadJevPreview('{$target}', '{$csstarget}');});</script>";
$id = $this->id;
$html .= <<<DROPDOWN
<div class="dropdown btn-group" id="{$id}">
<button class="btn btn-default dropdown-toggle" type="button" id="dropdown{$target}" data-toggle="dropdown" aria-expanded="false">
Select Layout
<span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdown{$target}" id="dropdownUL_{$target}" role="menu">
<li role="presentation"><a role="menuitem" class="dropdownpopover" href="#" data-title="Current Customised Value" data-content="Custom Format String customised by you">Current Value</a></li>
</ul>
</div>
DROPDOWN;
return $html;
}
示例11: countdownYTShortcode
function countdownYTShortcode($atts = null, $content = null)
{
$atts = ytshortcode_atts(array('count_date' => '2020/12/25', 'count_time' => '', 'count_size' => '32', 'count_color' => '', 'background' => '#FFFFFF', 'text_align' => 'default', 'text_size' => '14', 'text_color' => '#666666', 'align' => 'left', 'padding' => '', 'margin' => '', 'border' => '0px solid #DDD', 'radius' => '', 'divider' => 'none', 'divider_color' => 'rgba(100,100,100,.1)', 'class' => ''), $atts, 'countdown');
$id = uniqid('yt_countdown_') . rand() . time();
$css = '';
$js = '';
$divider_style = '';
if ($atts['divider'] == 'colon') {
$divider_style = '#' . $id . ' .yt-countdown-content .yt-cd-timer > span:after { font-size: ' . round($atts['count_size'] / 2) . 'px;line-height: ' . round($atts['count_size'] / 2) . 'px; color: ' . $atts['divider_color'] . ';}';
}
if ($atts['divider'] == 'vertical_line' || $atts['divider'] == 'horizontal_line') {
$divider_style = '#' . $id . ' .yt-countdown-content .yt-cd-timer > span:after {background-color: ' . $atts['divider_color'] . ';}';
} else {
$divider_style = '#' . $id . ' .yt-countdown-content .yt-cd-timer > span:after { font-size: ' . $atts['count_size'] . 'px;line-height: ' . $atts['count_size'] . 'px; color: ' . $atts['divider_color'] . ';}';
}
if ($atts['margin'] or $atts['padding'] or $atts['radius'] or $atts['border'] or $atts['background']) {
$margin = $atts['margin'] ? 'margin: ' . $atts['margin'] . ';' : '';
$padding = $atts['padding'] ? 'padding: ' . $atts['padding'] . ';' : '';
$radius = $atts['radius'] ? 'border-radius: ' . $atts['radius'] . ';' : '';
$border = $atts['border'] ? 'border: ' . $atts['border'] . ';' : '';
$background = $atts['background'] ? 'background-color: ' . $atts['background'] . ';' : '';
$css .= '#' . $id . ' {' . $margin . $padding . $radius . $border . $background . '}';
}
$count_color = $atts['count_color'] ? 'color: ' . $atts['count_color'] . ';' : '';
$css .= '#' . $id . ' .yt-cd-timer > span span[class*="text"] { color: ' . $atts['text_color'] . '; font-size: ' . $atts['text_size'] . 'px; }
#' . $id . ' .yt-cd-timer span > span { font-size: ' . $atts['count_size'] . 'px; line-height: ' . $atts['count_size'] . 'px; ' . $count_color . '}
' . $divider_style . '
';
$message = '';
$countdown = $atts['count_date'];
$countdown .= $atts['count_time'] ? ' ' . $atts['count_time'] : '';
if (isset($content)) {
$message = '.on("finish.countdown", function(event) {
$(this).parent()
.addClass("disabled")
.html("' . parse_shortcode(str_replace(array("<br/>", "<br>", "<br />", "<p>", "</p>"), " ", $content)) . '");
})';
}
$js .= '
jQuery(document).ready(function ($) {
$("#' . $id . ' .yt-cd-timer").countdown("' . $countdown . '").on("update.countdown", function(event) {
var $this = $(this).html(event.strftime(
"<span class=\'yt-cd-day\'><span class=\'yt-cd-day-data\'>%-D</span> <span class=\'yt-cd-day-text\'>DAY</span></span> "
+ "<span class=\'yt-cd-hour\'><span class=\'yt-cd-hour-data\'>%H</span> <span class=\'yt-cd-hour-text\'>HOUR</span></span> "
+ "<span class=\'yt-cd-minute\'><span class=\'yt-cd-minute-data\'>%M</span> <span class=\'yt-cd-minute-text\'>MIN</span></span> "
+ "<span class=\'yt-cd-second\'><span class=\'yt-cd-second-data\'>%S</span> <span class=\'yt-cd-second-text\'>SEC</span></span>"));
})' . $message . ';
});
';
JHtml::stylesheet(JUri::base() . "plugins/system/ytshortcodes/shortcodes/countdown/css/countdown.css", 'text/css');
JHtml::script(JUri::base() . "plugins/system/ytshortcodes/shortcodes/countdown/js/jquery.countdown.js");
$doc = JFactory::getDocument();
$doc->addStyleDeclaration($css);
$doc->addScriptDeclaration($js);
return '<div id="' . $id . '" class="yt-countdown-wrapper clearfix yt-countdown-' . $atts['align'] . ' yt-cd-divider-' . $atts['divider'] . ' yt-countdown-text-' . $atts['text_align'] . '">
<div class="yt-countdown-content">
<div class="yt-cd-timer"></div>
</div>
</div>';
}
示例12: include_jquery
public static function include_jquery($extension = '', $framework = false, $relative = true)
{
if (version_compare(JVERSION, '3.0.0', '>=')) {
JHtmlJquery::framework();
} else {
$doc = JFactory::getDocument();
if (!isset($doc->jquery_loaded)) {
if (JHtml::script('jquery.min.js', $framework, $relative, $pathonly = true)) {
JHtml::script('jquery.min.js', $framework, $relative);
JHtml::script('jquery.noconflict.js', $framework, $relative);
$doc->jquery_loaded = true;
return;
} else {
if (!empty($extension)) {
$jquery = $extension . '/jquery.min.js';
$jqueryNC = $extension . '/jquery.noconflict.js';
// should be locate as jquery.min.js
if (JHtml::script($jquery, $framework, $relative, $pathonly = true)) {
JHtml::script($jquery, $framework, $relative);
JHtml::script($jqueryNC, $framework, $relative);
$doc->jquery_loaded = true;
}
}
}
}
}
}
示例13: getInput
protected function getInput()
{
$this->params = $this->element->attributes();
JHtml::_('jquery.framework');
JHtml::script('nnframework/script.min.js', false, true);
$file = $this->def('file');
if (!$file) {
$path = $this->def('path') == 'site' ? '' : '/administrator';
$label = $this->def('label');
$file = $this->def('alias', $label);
$file = preg_replace('#[^a-z-]#', '', strtolower($file));
$extension = $this->def('extension');
switch ($extension) {
case 'com':
$file = $path . '/components/com_' . $file . '/com_' . $file . '.xml';
break;
case 'mod':
$file = $path . '/modules/mod_' . $file . '/mod_' . $file . '.xml';
break;
case 'plg_editors-xtd':
$file = '/plugins/editors-xtd/' . $file . '.xml';
break;
default:
$file = '/plugins/system/' . $file . '.xml';
break;
}
$label = JText::_($label) . ' (' . JText::_('NN_' . strtoupper($extension)) . ')';
} else {
$label = $this->def('label', 'the main extension');
}
nnFieldDependency::setMessage($file, $label);
return '';
}
示例14: onContentAfterDisplay
/**
* Displays the comments area
*
* @param string $context The context of the content being passed to the plugin
* @param object &$row The article object
* @param object &$params The article params
* @param integer $page The 'page' number
*
* @return mixed html string containing code for the comment if in com_content.article else boolean false
*
*/
public function onContentAfterDisplay($context, &$row, &$params, $page = 0)
{
$parts = explode(".", $context);
$plgCatid = $this->params->def('catid');
// Check is run com_content
if ($parts[0] != 'com_content') {
return false;
}
// Check category of the plugin in the allowable category array of the plugin
if ($plgCatid[0] != 'all' && !in_array($row->catid, $plgCatid)) {
return false;
}
// Add media file
JHtml::_('jquery.framework');
JHtml::script(JUri::base() . 'media/pkg_mjcommentsystem/plg_content_mjformcomment/js/plg_mjformcomment.js', false, true);
JHtml::stylesheet(JUri::base() . 'media/pkg_mjcommentsystem/plg_content_mjformcomment/css/plg_mjformcomment.css', false, true, false);
// Add the language file of the component
$lang = JFactory::getLanguage();
$basePath = JPATH_SITE . '/components/com_mjcomments';
$lang->load('com_mjcomments', $basePath, null, true);
// Assign value to the layout variables
$content_id = $row->id;
$formReturn = 'index.php?option=com_mjcomments&task=comment.send&format=json';
// Get the comment form
$this->setCommentForm();
// Get the comment list
$this->setCommentList($content_id);
// Name of the variables that will be used in the layout
$data = array('view' => $context, 'form' => $this->form, 'formReturn' => $formReturn, 'content_id' => $content_id, 'comments' => $this->comments);
return JLayoutHelper::render('default', compact('data'), __DIR__ . '/layouts');
}
示例15: display
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return void
*
* @since 2.5
*/
public function display($tpl = null)
{
JHtml::_('behavior.framework');
JHtml::stylesheet('com_finder/indexer.css', false, true, false);
JHtml::script('com_finder/indexer.js', false, true);
parent::display();
}