Skip to content

Commit

Permalink
Version 2.6.1 delivered 07 January 2013 19:47
Browse files Browse the repository at this point in the history
Warning

IT IS MANDATORY TO COMPLETELY REMOVE ALL VERSION < 2.6.0 BEFORE INSTALLING THIS NEW ONE!
Go to the Extension Manager under the tab Manage, enter in filter "tag", select all and click Actions – Uninstall
Reason: I did change a lot of folder name and file casing casing to be more Joomla compliant
Don’t be scared you will not loose any Tags or data from your database! uninstalling do not remove currently any tables!

2.6.1

cedThumbnails support in cedTag! cedThumbnails show Related Stories Under Each Post, it is a small widget that appears under each post, linking to related stories from your blog archive,
cedThumbnails links to stories that are relevant and interesting to readers of a particular post, keeping them engaged with your blog, and increasing your traffic!
You can now use Tags from cedTag to display related articles in Joomla. You can choose either
* CedThumbnails  (require extension CedThumbnails)
* Joomla - using Meta-Keywords

Maintenance Page: This new page will let you perform basic maintenance operations. Feel Free to ask for more operations using the support channel (Forums or Feedback (UserVoice))
* Replace Tag xxxx with Tag yyyy in all articles with Tag xxxx
* Add Tag yyyy to all articles which have also Tag xxxx
* Remove Tag xxxx to all articles which have also Tag yyyy.

NEW: change position of tag in category view, blog view that you can set tags to appear after intro text (show after text before readmore button)
NEW: version of extension is now displayed in administrator backend panel.
NEW: Adding a  “Clear All” button in   “TERM MANAGER” to remove all Tags and all

Bug Fixing
BUG: fix 500 error This error is now solved for good, was in cedtag component SEF (Thanks to Signature Ltd)
BUG: missing CSS style on ads top

Miscellaneous
The whole code has been validated using PHP code guidelines PSR-0/PSR-1/PSR-2
  • Loading branch information
cedricwalter committed Feb 22, 2013
1 parent 8c6c675 commit fb273cd
Show file tree
Hide file tree
Showing 62 changed files with 2,074 additions and 1,169 deletions.
49 changes: 49 additions & 0 deletions administrator/components/com_cedtag/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Tag for Joomla 2.5

## About
CedTag displays a list of tags in what is called a 'tag cloud', where the size of each tag is determined by how many times that particular tag has been assigned to posts.
Additionally, it is possible to sort tags by count and alphabetically at the same time. It is also possible to add a counter to the tags, so that your visitors can see how many posts are associated with each tag. The plugin also adds a sensible CSS class to every tag.
migration from http://extensions.joomla.org/extensions/search-&-indexing/tags-&-clouds/7718/details


### A real free tag system for Joomla.
Front end features:
* Show tags at the bottom of each article.

## Joomla Modules
* Tag list view
* Tag blog view
* Most popular tags.
* Most hits tags.
* Latest tags.

* SEF support, compatible with sh404SEF,ARTIO JoomSEF,AceSEF
* XMap Plugin
* Language file support
* Add/Edit tags
* Compatible with JoomlFish
* Search plugin.


### Back end features:

* Import Tags from Meta keywords / JTags / Joomla Tags
* Export Tags back to Joomla Meta keywords
* Term editable.
* Batch term add.
* Batch tag management.
* Auto extractable tag.
* Language file support
* Template edit online.
* Tags filter by section and category.
* One click installation.

## Documentation
http://wiki.waltercedric.com/index.php?title=Taxonomies_and_Tags_support_for_Joomla#Major_features

## Support
http://forums.waltercedric.com/

## License
http://www.gnu.org/copyleft/gpl.html

5 changes: 5 additions & 0 deletions administrator/components/com_cedtag/cedtag.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@
**/
defined('_JEXEC') or die('Restricted access');

// Access check.
if (!JFactory::getUser()->authorise('core.manage', 'com_cedtag')) {
throw new Exception(JText::_('JERROR_ALERTNOAUTHOR'), 401);
}

// Include dependencies
jimport('joomla.application.component.controller');

Expand Down
420 changes: 126 additions & 294 deletions administrator/components/com_cedtag/config.xml

Large diffs are not rendered by default.

6 changes: 4 additions & 2 deletions administrator/components/com_cedtag/controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
* @copyright (C) 2012 http://www.waltercedric.com
* @license GNU/GPL http://www.gnu.org/copyleft/gpl.html
**/
defined('_JEXEC') or die('Restricted access');

jimport('joomla.application.component.controller');
jimport( 'joomla.application.input' );

Expand All @@ -16,12 +18,12 @@ class CedTagController extends JController
{
protected $default_view = 'frontpage';

public function display($cachable = false, $urlparams = false)
public function display($cacheable = false, $urlParams = false)
{
$view = JFactory::getApplication()->input->get('view');
if (!isset($view)) {
JFactory::getApplication()->input->set('view', 'frontpage');
}
parent::display();
parent::display($cacheable,$urlParams);
}
}
4 changes: 2 additions & 2 deletions administrator/components/com_cedtag/controllers/css.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
jimport('joomla.filesystem.file');

require_once (JPATH_COMPONENT . '/controllers/file.php');
require_once JPATH_SITE . '/components/com_cedtag/helpers/helper.php';
require_once JPATH_SITE . '/components/com_cedtag/helpers/themes.php';
require_once (JPATH_SITE . '/components/com_cedtag/helpers/helper.php');
require_once (JPATH_SITE . '/components/com_cedtag/helpers/themes.php');


class CedTagControllerCss extends CedTagControllerFile
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,11 @@ public function execute($task)
}

/**
* @param bool $cachable
* @param bool $urlparams
* @param bool $cacheable
* @param bool $urlParams
* @return JController|void
*/
public function display($cachable = false, $urlparams = false)
public function display($cacheable = false, $urlParams = false)
{
JFactory::getApplication()->input->set('view', 'diagnostic');
parent::display();
Expand Down
7 changes: 4 additions & 3 deletions administrator/components/com_cedtag/controllers/export.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,11 @@ public function execute($task)
}

/**
* @param bool $cachable
* @param bool $urlparams
* @param bool $cacheable
* @param bool $urlParams
* @return JController|void
*/
public function display($cachable = false, $urlparams = false)
public function display($cacheable = false, $urlParams = false)
{
JFactory::getApplication()->input->set('view', 'export');
parent::display();
Expand Down
19 changes: 17 additions & 2 deletions administrator/components/com_cedtag/controllers/file.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function execute($task)
}
}

public function display($cachable = false, $urlparams = false)
public function display($cacheable = false, $urlParams = false)
{
JFactory::getApplication()->input->set('view', $this->getDefaultView());
parent::display();
Expand Down Expand Up @@ -68,17 +68,32 @@ public function transform($fileContent)
return $fileContent;
}

/**
* to be overriden
* @return string
*/
public function getDefaultFile()
{
return "";
}

/**
* to be overriden
* @return string
*/
public function getFile()
{
return "";
}

// dont name this getView() as joomla use this already
/**
* dont name this getView() as joomla use this already
* to be overriden
* @return string
*/
public function getDefaultView()
{
return "";
}

public function restore()
Expand Down
3 changes: 2 additions & 1 deletion administrator/components/com_cedtag/controllers/import.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ public function execute($task)
/**
* @param bool $cachable
* @param bool $urlparams
* @return JController|void
*/
public function display($cachable = false, $urlparams = false)
public function display($cacheable = false, $urlparams = false)
{
JFactory::getApplication()->input->set('view', 'import');
parent::display();
Expand Down
36 changes: 32 additions & 4 deletions administrator/components/com_cedtag/controllers/maintenance.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ public function execute($task)
{
$input = JFactory::getApplication()->input;

$tagX = $input->get('tagxxxx', null);
$tagX = $input->get('tagxxxx', null, 'string');
$articles = $input->get('articles', null, 'int');

$tagY = $input->get('tagyyyy', null);
$tagYWeigtht = $input->get('tagyyyyweigtht', null);
$tagYDescription = $input->get('tagyyyydescription', null);
$tagY = $input->get('tagyyyy', null, 'string');
$tagYWeigtht = $input->get('tagyyyyweigtht', null, 'int');
$tagYDescription = $input->get('tagyyyydescription', null, 'string');

switch ($task) {
case 'replace':
Expand All @@ -37,6 +38,12 @@ public function execute($task)
case 'remove':
$this->remove($tagX, $tagY);
break;
case 'publish':
$this->publish($articles);
break;
case 'publish':
$this->unpublish($articles);
break;
default:
$this->display();
}
Expand All @@ -45,13 +52,34 @@ public function execute($task)
/**
* @param bool $cachable
* @param bool $urlparams
* @return JController|void
*/
public function display($cachable = false, $urlparams = false)
{
JFactory::getApplication()->input->set('view', 'maintenance');
parent::display();
}

private function unpublish($articles)
{
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));

$model = $this->getModel('maintenance');
$message = $model->unpublish($articles);

$this->setRedirect("index.php?option=com_cedtag&controller=maintenance", $message);
}

private function publish($articles)
{
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));

$model = $this->getModel('maintenance');
$message = $model->publish($articles);

$this->setRedirect("index.php?option=com_cedtag&controller=maintenance", $message);
}

/**
* Remove Tag xxxx to all articles which have also Tag yyyy
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ public function execute($task)
/**
* @param bool $cachable
* @param bool $urlparams
* @return JController|void
*/
public function display($cachable = false, $urlparams = false)
{
Expand Down
4 changes: 3 additions & 1 deletion administrator/components/com_cedtag/controllers/tag.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ public function execute($task)
/**
* @param bool $cachable
* @param bool $urlparams
* @return \JController|void
*/
public function display($cachable = false, $urlparams = false)
{
Expand Down Expand Up @@ -146,7 +147,8 @@ private function ajaxSuggest()
JSession::checkToken('get') or jexit(JText::_('JINVALID_TOKEN'));

$CedTagsHelper = new CedTagsHelper();
$partialTag = JRequest::getVar('term', '', 'get', 'cmd');
$partialTag = JFactory::getApplication()->input->get('term');

return $CedTagsHelper->getTagModel()->suggestJson($partialTag);
}

Expand Down
33 changes: 31 additions & 2 deletions administrator/components/com_cedtag/controllers/term.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
jimport('joomla.application.controller');
jimport('joomla.application.input');

// userhelper for acl
require_once JPATH_SITE . '/administrator/components/com_users/helpers/users.php';

class CedTagControllerTerm extends JController
{
function __construct()
Expand All @@ -30,6 +33,9 @@ public function execute($task)
case 'remove':
$this->remove();
break;
case 'clearall':
$this->clearall();
break;
case 'batchadd':
$this->batchAdd();
break;
Expand Down Expand Up @@ -85,9 +91,10 @@ private function save()
$name = $input->get('name', '', 'POST');

//Argh this work
$description = JRequest::getVar( 'description', '', 'post', 'string', JREQUEST_ALLOWHTML );
$description = JRequest::getVar('description', '', 'post', 'string', JREQUEST_ALLOWHTML);

//but not is one
// $input->get('description', '', 'post', 'string', JREQUEST_ALLOWHTML);
//$description = $input->get('description', '', 'none');

$weight = $input->get('weight', '', 'post');
$model = $this->getModel('term');
Expand Down Expand Up @@ -131,6 +138,28 @@ private function remove()
$this->setRedirect("index.php?option=com_cedtag&controller=term", $msg);
}


private function clearall()
{
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));

$canDo = UsersHelper::getActions();
if ($canDo->get('core.delete')) {
$model = $this->getModel('term');
$res = $model->clearall();
if ($res) {
$msg = JText::_('All Terms and all Tags have been removed from all articles');
} else {
$msg = JText::_('Failed to remove all Terms');
}
} else {
$msg = JText::_('YOU DO NOT HAVE ENOUGH PERMISSIONS TO CLEAR ALL TERMS');
}

$this->setRedirect("index.php?option=com_cedtag&controller=term", $msg);
}


private function batchAdd()
{
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));
Expand Down
Loading

0 comments on commit fb273cd

Please sign in to comment.