Я создал простой тестовый плагин для отображения некоторого текста перед статьями, но он ничего не отображает перед текстом статьи.Простой плагин Joomla 3 не отображает
<?php
// no direct access
defined('_JEXEC') or die;
class plgContentArticlePhoto extends JPlugin
{
protected $autoloadLanguage = true;
function onContentPrepare($context, &$article, &$params, $limitstart)
{
$test = 'test plugin ';
$article->text = $test . $article->text;
return true;
}
}
?>
XML-файл:
<?xml version="1.0" encoding="utf-8"?>
<extension version="3.2" type="plugin" group="content" method="upgrade">
<name>Article Photo</name>
<author>JV</author>
<creationDate>August 2016</creationDate>
<copyright>Copyright (C) 2005 - 2013 Open Source Matters. All rights reserved.</copyright>
<license>GNU General Public License version 2 or later; see LICENSE.txt</license>
<authorEmail></authorEmail>
<authorUrl></authorUrl>
<version>1.0</version>
<description>Article Photo</description>
<files>
<filename plugin="article_photo">article_photo.php</filename>
<filename>index.html</filename>
</files>
<config>
</config>
</extension>
Может somenone помочь? Thanks
Вы можете показать свой файл XML? –