[pLog-svn] r4925 - in plugins/branches/lifetype-1.2: akismet ayearago categorybrowser googleanalytics gravatar openid recentcomments reflection requireemail templateeditor validatetrackback
jondaley at devel.lifetype.net
jondaley at devel.lifetype.net
Fri Mar 2 11:45:36 EST 2007
Author: jondaley
Date: 2007-03-02 11:45:36 -0500 (Fri, 02 Mar 2007)
New Revision: 4925
Modified:
plugins/branches/lifetype-1.2/akismet/pluginakismet.class.php
plugins/branches/lifetype-1.2/ayearago/pluginayearago.class.php
plugins/branches/lifetype-1.2/categorybrowser/plugincategorybrowser.class.php
plugins/branches/lifetype-1.2/googleanalytics/plugingoogleanalytics.class.php
plugins/branches/lifetype-1.2/gravatar/plugingravatar.class.php
plugins/branches/lifetype-1.2/openid/pluginopenid.class.php
plugins/branches/lifetype-1.2/recentcomments/pluginrecentcomments.class.php
plugins/branches/lifetype-1.2/reflection/pluginreflection.class.php
plugins/branches/lifetype-1.2/requireemail/pluginrequireemail.class.php
plugins/branches/lifetype-1.2/templateeditor/plugintemplateeditor.class.php
plugins/branches/lifetype-1.2/validatetrackback/pluginvalidatetrackback.class.php
Log:
removed PluginManager include, since most plugins don't need it. updated and moved includes.
Modified: plugins/branches/lifetype-1.2/akismet/pluginakismet.class.php
===================================================================
--- plugins/branches/lifetype-1.2/akismet/pluginakismet.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/akismet/pluginakismet.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -18,9 +18,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
- include_once( PLOG_CLASS_PATH."plugins/akismet/class/security/akismetfilter.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
class PluginAkismet extends PluginBase
{
@@ -34,7 +32,7 @@
$this->desc = "Akismet checks your comments against the Akismet web serivce to see if they look like spam or not.";
$this->author = "Paul Westbrook (Akismet php library provided by <a href=\"http://miphp.net/blog/view/php4_akismet_class\">Bret Kuhns</a>)";
$this->locales = Array( "en_UK" );
- $this->version = "20070226";
+ $this->version = "20070302";
if( $source == "admin" )
$this->initAdmin();
@@ -44,18 +42,19 @@
function init()
{
+ lt_include( PLOG_CLASS_PATH."plugins/akismet/class/security/akismetfilter.class.php" );
//register the filter
$this->registerFilter( "AkismetFilter" );
}
function initAdmin()
{
- $this->registerFilter( "AkismetFilter" );
+ $this->init();
$this->registerAdminAction( "akismet", "PluginAkismetConfigAction" );
$this->registerAdminAction( "updateAkismetConfig", "PluginAkismetUpdateConfigAction" );
- include_once( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$menu =& Menu::getMenu();
if( !$menu->entryExists( "/menu/controlCenter/manageAntiSpamPlugins" ))
Modified: plugins/branches/lifetype-1.2/ayearago/pluginayearago.class.php
===================================================================
--- plugins/branches/lifetype-1.2/ayearago/pluginayearago.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/ayearago/pluginayearago.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -1,6 +1,5 @@
<?php
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
/**
* Plugin that returns an array of posts written a year before
@@ -17,7 +16,7 @@
$this->id = "ayearago";
$this->author = "Mariano Draghi (cHagHi)";
$this->desc = "This plugin offers various methods to get a list of posts written a year before a given post, or based on the current date.";
- $this->version = '20070228';
+ $this->version = '20070302';
$this->locales = Array( "en_UK", "es_ES" );
if( $source == "admin" )
@@ -26,10 +25,13 @@
function initAdmin()
{
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$this->registerAdminAction( "ayearago", "PluginAYearAgoConfigAction" );
- $this->registerAdminAction( "updateAYearAgoConfig", "PluginAYearAgoUpdateConfigAction" );
+ $this->registerAdminAction( "updateAYearAgoConfig",
+ "PluginAYearAgoUpdateConfigAction" );
- $this->addMenuEntry( "/menu/controlCenter/manageSettings", "AYearAgo", "?op=ayearago", "" );
+ $this->addMenuEntry( "/menu/controlCenter/manageSettings",
+ "AYearAgo", "?op=ayearago", "" );
}
function register()
Modified: plugins/branches/lifetype-1.2/categorybrowser/plugincategorybrowser.class.php
===================================================================
--- plugins/branches/lifetype-1.2/categorybrowser/plugincategorybrowser.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/categorybrowser/plugincategorybrowser.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -1,10 +1,9 @@
<?php
-include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
-include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
-include_once( PLOG_CLASS_PATH."class/dao/articles.class.php" );
-include_once( PLOG_CLASS_PATH."class/dao/article.class.php" );
-include_once( PLOG_CLASS_PATH."class/database/db.class.php" );
+lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
+lt_include( PLOG_CLASS_PATH."class/dao/articles.class.php" );
+lt_include( PLOG_CLASS_PATH."class/dao/article.class.php" );
+lt_include( PLOG_CLASS_PATH."class/database/db.class.php" );
/*
* Plugin that offers features to return links to the next and previous articles
Modified: plugins/branches/lifetype-1.2/googleanalytics/plugingoogleanalytics.class.php
===================================================================
--- plugins/branches/lifetype-1.2/googleanalytics/plugingoogleanalytics.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/googleanalytics/plugingoogleanalytics.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -1,7 +1,6 @@
<?php
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
/**
* offers features to inset google analytics javascript codes in tempalte header.
@@ -18,7 +17,7 @@
$this->id = "googleanalytics";
$this->author = "lss";
$this->desc = "This plugin offers features to inset google analytics javascript codes in tempalte header";
- $this->version = "20070226";
+ $this->version = "20070302";
$this->locales = Array( "en_UK" , "zh_TW" , "zh_CN", "es_ES" );
@@ -28,6 +27,7 @@
function initAdmin()
{
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$this->registerAdminAction( "googleanalytics", "PluginGoogleAnalyticsConfigAction" );
$this->registerAdminAction( "updategoogleanalytics", "PluginGoogleAnalyticsUpdateConfigAction" );
@@ -50,17 +50,18 @@
/**
* Returns google analytics javascript
*/
- function getJavascriptCode()
- {
- $jsCode = "";
- if( $this->isEnabled() ){
- $jsCode ="<script src=\"http://www.google-analytics.com/urchin.js\" type=\"text/javascript\">\n"
+ function getJavascriptCode(){
+ $jsCode = "";
+ if( $this->isEnabled() ){
+ $jsCode ="<script "
+ ."src=\"http://www.google-analytics.com/urchin.js\" "
+ ."type=\"text/javascript\">\n"
."</script>\n"
."<script type=\"text/javascript\">\n"
."_uacct = \"".$this->uacct."\";\n"
."urchinTracker();\n"
."</script>\n";
- }
+ }
return $jsCode;
}
}
Modified: plugins/branches/lifetype-1.2/gravatar/plugingravatar.class.php
===================================================================
--- plugins/branches/lifetype-1.2/gravatar/plugingravatar.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/gravatar/plugingravatar.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -1,8 +1,6 @@
<?php
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
- include_once( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
/**
* Mostra un avatar a cada comentari descarregant-lo de Gravatar.com. Versió 0.2
@@ -24,7 +22,7 @@
$this->id = "gravatar";
$this->author = "Original by Dani Armengol, Modified by Mark Wu";
$this->desc = "Returns the URL of an (gr)avatar for every comment. The image is loaded from Gravatar.com";
- $this->version = "20070226";
+ $this->version = "20070302";
$this->init();
}
@@ -32,13 +30,16 @@
function init()
{
if( $this->getSource() == "admin") {
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$this->registerAdminAction( "gravatar", "PluginGravatarConfigAction" );
$this->registerAdminAction( "updateGravatarConfig", "PluginGravatarUpdateConfigAction" );
$menu =& Menu::getMenu();
- if( !$menu->entryExists( "/menu/controlCenter/manageAppearancePlugins" ))
- $this->addMenuEntry( "/menu/controlCenter", "manageAppearancePlugins", "", "", true, false );
- $this->addMenuEntry( "/menu/controlCenter/manageAppearancePlugins", "Gravatar", "?op=gravatar", "" );
+ if( !$menu->entryExists("/menu/controlCenter/manageAppearancePlugins" ))
+ $this->addMenuEntry("/menu/controlCenter", "manageAppearancePlugins",
+ "", "", true, false );
+ $this->addMenuEntry("/menu/controlCenter/manageAppearancePlugins",
+ "Gravatar", "?op=gravatar", "" );
}
}
Modified: plugins/branches/lifetype-1.2/openid/pluginopenid.class.php
===================================================================
--- plugins/branches/lifetype-1.2/openid/pluginopenid.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/openid/pluginopenid.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -18,8 +18,7 @@
*/
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
class PluginOpenid extends PluginBase
{
@@ -32,7 +31,7 @@
$this->id = "openid";
$this->author = "Paul Westbrook (phpMyID provided by <a href=\"http://siege.org/projects/phpMyID/\">CJ Niemira</a>)";
$this->desc = "Plugin to add OpenID support to LifeType.";
- $this->version = "20070226";
+ $this->version = "20070302";
$this->locales = Array( "en_UK");
@@ -42,6 +41,7 @@
function initAdmin()
{
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$this->registerAdminAction( "openidConfig", "PluginOpenidConfigAction" );
$this->registerAdminAction( "updateOpenidConfig", "PluginOpenidUpdateConfigAction" );
Modified: plugins/branches/lifetype-1.2/recentcomments/pluginrecentcomments.class.php
===================================================================
--- plugins/branches/lifetype-1.2/recentcomments/pluginrecentcomments.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/recentcomments/pluginrecentcomments.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -1,7 +1,6 @@
<?php
lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- lt_include( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
/**
* Plugin that offers features to return a recent article comments from the current blog
Modified: plugins/branches/lifetype-1.2/reflection/pluginreflection.class.php
===================================================================
--- plugins/branches/lifetype-1.2/reflection/pluginreflection.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/reflection/pluginreflection.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -18,8 +18,7 @@
*/
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
class PluginReflection extends PluginBase
{
@@ -32,7 +31,7 @@
$this->id = "reflection";
$this->author = "Paul Westbrook";
$this->desc = "Plugin to add reflections to images.";
- $this->version = "20070226";
+ $this->version = "20070302";
$this->locales = Array( "en_UK");
@@ -64,7 +63,6 @@
function show()
{
-
$str = '';
if ($this->isEnabled())
Modified: plugins/branches/lifetype-1.2/requireemail/pluginrequireemail.class.php
===================================================================
--- plugins/branches/lifetype-1.2/requireemail/pluginrequireemail.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/requireemail/pluginrequireemail.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -18,9 +18,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
- include_once( PLOG_CLASS_PATH."plugins/requireemail/class/security/requireemailfilter.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
class PluginRequireEmail extends PluginBase
{
@@ -34,7 +32,7 @@
$this->desc = "The Require Email plugin requires that an email is entered for comments.";
$this->author = "Paul Westbrook";
$this->locales = Array( "en_UK" );
- $this->version = "20070228";
+ $this->version = "20070302";
if( $source == "admin" )
@@ -45,18 +43,19 @@
function init()
{
+ lt_include(PLOG_CLASS_PATH."plugins/requireemail/class/security/requireemailfilter.class.php");
$this->registerFilter( "RequireEmailFilter" );
}
function initAdmin()
{
- $this->registerFilter( "RequireEmailFilter" );
+ $this->init();
$this->registerAdminAction( "requireemail", "PluginRequireEmailConfigAction" );
$this->registerAdminAction( "updateRequireEmailConfig", "PluginRequireEmailUpdateConfigAction" );
- include_once( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$menu =& Menu::getMenu();
if( !$menu->entryExists( "/menu/controlCenter/manageAntiSpamPlugins" ))
Modified: plugins/branches/lifetype-1.2/templateeditor/plugintemplateeditor.class.php
===================================================================
--- plugins/branches/lifetype-1.2/templateeditor/plugintemplateeditor.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/templateeditor/plugintemplateeditor.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -1,6 +1,5 @@
<?php
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
define( "MAX_BACKUP_FILES", 5);
define( "EDITABLE_EXTENSION", "css,inc,template,txt" );
@@ -16,7 +15,7 @@
$this->id = "templateeditor";
$this->author = "Mark Wu";
$this->desc = "The plugin offer online template editor function for LifeType";
- $this->version = "20070226";
+ $this->version = "20070302";
$config =& Config::getConfig();
$this->pluginEnabled = $config->getValue( "plugin_templateeditor_enabled" );
Modified: plugins/branches/lifetype-1.2/validatetrackback/pluginvalidatetrackback.class.php
===================================================================
--- plugins/branches/lifetype-1.2/validatetrackback/pluginvalidatetrackback.class.php 2007-03-02 16:35:11 UTC (rev 4924)
+++ plugins/branches/lifetype-1.2/validatetrackback/pluginvalidatetrackback.class.php 2007-03-02 16:45:36 UTC (rev 4925)
@@ -18,9 +18,8 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
- include_once( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
- include_once( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
- include_once( PLOG_CLASS_PATH."plugins/validatetrackback/class/security/validatetrackbackfilter.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/plugin/pluginbase.class.php" );
+
/**
* implements moderation of comments
@@ -37,7 +36,7 @@
$this->desc = "Provides validation of trackbacks.";
$this->author = "Paul Westbrook";
$this->locales = Array( "en_UK", "zh_TW", "es_ES" );
- $this->version = "20070226";
+ $this->version = "20070302";
if( $source == "admin" )
$this->initAdmin();
@@ -45,10 +44,10 @@
$this->init();
}
- function init()
- {
- // register the filter
- $this->registerFilter( "ValidateTrackbackFilter" );
+ function init(){
+ lt_include( PLOG_CLASS_PATH."plugins/validatetrackback/class/security/validatetrackbackfilter.class.php" );
+ // register the filter
+ $this->registerFilter( "ValidateTrackbackFilter" );
}
@@ -57,6 +56,8 @@
*/
function initAdmin()
{
+ lt_include( PLOG_CLASS_PATH."plugins/validatetrackback/class/security/validatetrackbackfilter.class.php" );
+ lt_include( PLOG_CLASS_PATH."class/template/menu/menu.class.php" );
$this->registerFilter( "ValidateTrackbackFilter" );
// register an action that will allow users to see which comments have not been
More information about the pLog-svn
mailing list