1st commit for syncing own Jlog developments with master
This commit is contained in:
parent
2ae67af572
commit
517c58344d
54 changed files with 1784 additions and 1062 deletions
|
@ -1,30 +1,34 @@
|
|||
<?php
|
||||
// FIXME Strict Standards
|
||||
|
||||
// hiervon werden die Plugins abgeleitet
|
||||
class JlogPlugin {
|
||||
|
||||
/* Hooks */
|
||||
function hook_body ($t) { return $t; } // string body
|
||||
function hook_commentForm ($t) { return $t; } // string with comment form output + array with form data
|
||||
function hook_commentForm ($t, $c) { return $t; } // string with comment form output + array with form data
|
||||
function hook_adminContent ($t) { return $t; } // string content
|
||||
function hook_newComment ($t) { return $t; } // array form data
|
||||
function hook_updateComment ($t) { return $t; } // array form data
|
||||
function hook_deleteComment ($t) { return $t; } // string comment id
|
||||
function hook_showComment ($t) { return $t; } // string comment output
|
||||
function hook_showComment($comment, $data, $nr) { return $comment; } // string comment output
|
||||
function hook_onUpdate ($t) { return $t; } // array with all rss feeds and sub
|
||||
function hook_doEntry ($t) { return $t; } // string with entry + array with data from database + string count comments + string section
|
||||
function hook_doEntry($output /* entry */,
|
||||
$dbData /* array with data from database */,
|
||||
$cc /* string count comments */,
|
||||
$section /* string section */) { return $output; }
|
||||
function hook_doTeaser ($t) { return $t; } // string with entry + array with data from database + string count comments + string pre + string post
|
||||
function hook_bbcode ($t) { return $t; } // bbcode object
|
||||
function hook_bbcomments ($t) { return $t; } // bbcomments object
|
||||
function hook_adminForm ($t) { return $t; } // admin formular
|
||||
function hook_insertEntry ($t) { return $t; } // int id + array with form data
|
||||
function hook_updateEntry ($t) { return $t; } // int id + array with form data
|
||||
function hook_adminForm($formHTML, $formData) { return $formHTML; } // admin formular
|
||||
function hook_insertEntry($id, $form /* bereits escaped */) {} // int id + array with form data
|
||||
function hook_updateEntry($id, $form) {} // int id + array with form data
|
||||
function hook_permalink ($t) { return $t; } // string permalink + string date + string url + string section
|
||||
function hook_xmlrpcPermalink ($t) { return $t; } // string url
|
||||
function hook_countComments ($t) { return $t; } // array with id and count
|
||||
function hook_adminMail ($t) { return $t; } // array with mail + array blogentry
|
||||
function hook_adminMail($mail, $blogentry, $id) { return $mail; } // array with mail + array blogentry
|
||||
function hook_commentorMail ($t) { return $t; } // array with mail + array blogentry
|
||||
function hook_commentAdminList($t) { return $t; } // string with actual tr + array with comment data
|
||||
function hook_commentAdminList($comment, $data) { return $comment; } // string with actual tr + array with comment data
|
||||
function hook_previewComment ($t) { return $t; } // same as newComment
|
||||
function hook_dispatchLogin ($t) { return $t; } //
|
||||
function hook_loginForm ($t) { return $t; } //
|
||||
|
@ -35,7 +39,7 @@ class JlogPlugin {
|
|||
class JlogPluginManager {
|
||||
var $plugins = array();
|
||||
|
||||
function JlogPluginManager($plugindirectory) {
|
||||
function __construct($plugindirectory) {
|
||||
$handle = "";
|
||||
$file = "";
|
||||
$this->get = strip($_GET);
|
||||
|
@ -72,7 +76,7 @@ class JlogPluginManager {
|
|||
foreach ($this->plugins as $plugin) {
|
||||
$parameters[0] = $hookresult;
|
||||
if($hook == 'hook_adminTitle' OR $hook == 'hook_adminContent') {
|
||||
if(strtolower($this->get['jplug']) === strtolower(get_class($plugin)))
|
||||
if(isset($this->get['jplug']) && strtolower($this->get['jplug']) === strtolower(get_class($plugin)))
|
||||
$hookresult = call_user_func_array(array($plugin, $hook), $parameters);
|
||||
}
|
||||
else $hookresult = call_user_func_array(array($plugin, $hook), $parameters);
|
||||
|
@ -80,4 +84,3 @@ class JlogPluginManager {
|
|||
return $hookresult;
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue