Skip to content
This repository has been archived by the owner on Nov 28, 2017. It is now read-only.

Moved things to layout #46

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions layouts/libraries/cms/html/batch/access.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;

extract($displayData);

/**
* Layout variables
* ---------------------
* $context : (string) The context of the content being passed to the plugin
* $row : (object) The article object
* $params : (JRegistry) The article params
* - showVoteForm : (boolean) Do we have to show the vote form?
* $page : (int) The 'page' number
*/


JHtml::_('bootstrap.tooltip', '.modalTooltip', array('container' => '.modal-body'));

// Create the batch selector to change an access level on a selection list.
echo
'<label id="batch-access-lbl" for="batch-access" class="modalTooltip" '
. 'title="' . JHtml::tooltipText('JLIB_HTML_BATCH_ACCESS_LABEL', 'JLIB_HTML_BATCH_ACCESS_LABEL_DESC') . '">'
. JText::_('JLIB_HTML_BATCH_ACCESS_LABEL')
. '</label>'
. JHtml::_(
'access.assetgrouplist',
'batch[assetgroup_id]', '',
'class="inputbox"',
array(
'title' => JText::_('JLIB_HTML_BATCH_NOCHANGE'),
'id' => 'batch-access'
)
);


42 changes: 42 additions & 0 deletions layouts/libraries/cms/html/batch/item.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;

extract($displayData);

/**
* Layout variables
* ---------------------
* $context : (string) The context of the content being passed to the plugin
* $row : (object) The article object
* $params : (JRegistry) The article params
* - showVoteForm : (boolean) Do we have to show the vote form?
* $page : (int) The 'page' number
*/


// Create the copy/move options.
$options = array(
JHtml::_('select.option', 'c', JText::_('JLIB_HTML_BATCH_COPY')),
JHtml::_('select.option', 'm', JText::_('JLIB_HTML_BATCH_MOVE'))
);

// Create the batch selector to change select the category by which to move or copy.
echo
'<label id="batch-choose-action-lbl" for="batch-choose-action">' . JText::_('JLIB_HTML_BATCH_MENU_LABEL') . '</label>'
. '<div id="batch-choose-action" class="control-group">'
. '<select name="batch[category_id]" class="inputbox" id="batch-category-id">'
. '<option value="">' . JText::_('JSELECT') . '</option>'
. JHtml::_('select.options', JHtml::_('category.options', $extension))
. '</select>'
. '</div>'
. '<div id="batch-move-copy" class="control-group radio">'
. JHtml::_('select.radiolist', $options, 'batch[move_copy]', '', 'value', 'text', 'm')
. '</div>';
38 changes: 38 additions & 0 deletions layouts/libraries/cms/html/batch/language.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;

extract($displayData);

/**
* Layout variables
* ---------------------
* $context : (string) The context of the content being passed to the plugin
* $row : (object) The article object
* $params : (JRegistry) The article params
* - showVoteForm : (boolean) Do we have to show the vote form?
* $page : (int) The 'page' number
*/


JHtml::_('bootstrap.tooltip', '.modalTooltip', array('container' => '.modal-body'));

// Create the batch selector to change the language on a selection list.
return
'<label id="batch-language-lbl" for="batch-language-id" class="modalTooltip"'
. ' title="' . JHtml::tooltipText('JLIB_HTML_BATCH_LANGUAGE_LABEL', 'JLIB_HTML_BATCH_LANGUAGE_LABEL_DESC') . '">'
. JText::_('JLIB_HTML_BATCH_LANGUAGE_LABEL')
. '</label>'
. '<select name="batch[language_id]" class="inputbox" id="batch-language-id">'
. '<option value="">' . JText::_('JLIB_HTML_BATCH_LANGUAGE_NOCHANGE') . '</option>'
. JHtml::_('select.options', JHtml::_('contentlanguage.existing', true, true), 'value', 'text')
. '</select>';


36 changes: 36 additions & 0 deletions layouts/libraries/cms/html/batch/tag.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;

extract($displayData);

/**
* Layout variables
* ---------------------
* $context : (string) The context of the content being passed to the plugin
* $row : (object) The article object
* $params : (JRegistry) The article params
* - showVoteForm : (boolean) Do we have to show the vote form?
* $page : (int) The 'page' number
*/


JHtml::_('bootstrap.tooltip', '.modalTooltip', array('container' => '.modal-body'));

// Create the batch selector to tag items on a selection list.
return
'<label id="batch-tag-lbl" for="batch-tag-id" class="modalTooltip"'
. ' title="' . JHtml::tooltipText('JLIB_HTML_BATCH_TAG_LABEL', 'JLIB_HTML_BATCH_TAG_LABEL_DESC') . '">'
. JText::_('JLIB_HTML_BATCH_TAG_LABEL')
. '</label>'
. '<select name="batch[tag]" class="inputbox" id="batch-tag-id">'
. '<option value="">' . JText::_('JLIB_HTML_BATCH_TAG_NOCHANGE') . '</option>'
. JHtml::_('select.options', JHtml::_('tag.tags', array('filter.published' => array(1))), 'value', 'text')
. '</select>';
43 changes: 43 additions & 0 deletions layouts/libraries/cms/html/batch/user.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;

extract($displayData);

/**
* Layout variables
* ---------------------
* $context : (string) The context of the content being passed to the plugin
* $row : (object) The article object
* $params : (JRegistry) The article params
* - showVoteForm : (boolean) Do we have to show the vote form?
* $page : (int) The 'page' number
*/

JHtml::_('bootstrap.tooltip', '.modalTooltip', array('container' => '.modal-body'));

$optionNo = '';

if ($noUser)
{
$optionNo = '<option value="0">' . JText::_('JLIB_HTML_BATCH_USER_NOUSER') . '</option>';
}

// Create the batch selector to select a user on a selection list.
return
'<label id="batch-user-lbl" for="batch-user" class="modalTooltip"'
. ' title="' . JHtml::tooltipText('JLIB_HTML_BATCH_USER_LABEL', 'JLIB_HTML_BATCH_USER_LABEL_DESC') . '">'
. JText::_('JLIB_HTML_BATCH_USER_LABEL')
. '</label>'
. '<select name="batch[user_id]" class="inputbox" id="batch-user-id">'
. '<option value="">' . JText::_('JLIB_HTML_BATCH_USER_NOCHANGE') . '</option>'
. $optionNo
. JHtml::_('select.options', JHtml::_('user.userlist'), 'value', 'text')
. '</select>';
45 changes: 45 additions & 0 deletions layouts/plugins/system/highlight/default.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;

extract($displayData);

/**
* Layout variables
* ---------------------
* $context : (string) The context of the content being passed to the plugin
* $row : (object) The article object
* $params : (JRegistry) The article params
* - showVoteForm : (boolean) Do we have to show the vote form?
* $page : (int) The 'page' number
*/



// Clean the terms array.
$filter = JFilterInput::getInstance();

$cleanTerms = array();

foreach ($terms as $term)
{
$cleanTerms[] = htmlspecialchars($filter->clean($term, 'string'));
}

// Activate the highlighter.
JHtml::_('behavior.highlighter', $cleanTerms);

// Adjust the component buffer.
$doc = JFactory::getDocument();
$buf = $doc->getBuffer('component');
$buf = '<br id="highlighter-start" />' . $buf . '<br id="highlighter-end" />';
$doc->setBuffer($buf, 'component');

return true;
Loading