当前位置: 首页>>代码示例>>PHP>>正文


PHP Doku_Event_Handler类代码示例

本文整理汇总了PHP中Doku_Event_Handler的典型用法代码示例。如果您正苦于以下问题:PHP Doku_Event_Handler类的具体用法?PHP Doku_Event_Handler怎么用?PHP Doku_Event_Handler使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了Doku_Event_Handler类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: register

 /**
  * Registers a callback function for a given event
  *
  * @param Doku_Event_Handler $controller DokuWiki's event controller object
  * @return void
  */
 public function register(Doku_Event_Handler $controller)
 {
     // ensure a page revision is created when struct data changes:
     $controller->register_hook('COMMON_WIKIPAGE_SAVE', 'BEFORE', $this, 'handle_pagesave_before');
     // save struct data after page has been saved:
     $controller->register_hook('COMMON_WIKIPAGE_SAVE', 'AFTER', $this, 'handle_pagesave_after');
 }
开发者ID:cosmocode,项目名称:dokuwiki-plugin-struct,代码行数:13,代码来源:revert.php

示例2: register

 /**
  * Registers a callback function for a given event
  *
  * @param Doku_Event_Handler $controller
  */
 function register(Doku_Event_Handler $controller)
 {
     $controller->register_hook('DOKUWIKI_STARTED', 'BEFORE', $this, 'check', array());
     $controller->register_hook('TPL_ACT_RENDER', 'BEFORE', $this, 'handle_act_render', array());
     $controller->register_hook('TPL_METAHEADER_OUTPUT', 'BEFORE', $this, 'handle_metaheader_output', array());
     $controller->register_hook('ACTION_HEADERS_SEND', 'BEFORE', $this, 'handle_headers_send', array());
 }
开发者ID:stupid-beard,项目名称:plugin-blogtng,代码行数:12,代码来源:linkback.php

示例3: register

 /**
  * Registers a callback function for a given event
  *
  * @param Doku_Event_Handler $controller the DokuWiki event controller object
  * @return void
  */
 public function register(Doku_Event_Handler $controller)
 {
     $controller->register_hook('TPL_ACT_RENDER', 'AFTER', $this, 'load_pagetools_script');
     $controller->register_hook('TEMPLATE_PAGETOOLS_DISPLAY', 'BEFORE', $this, 'add_button');
     Door43_Ajax_Helper::register_handler($controller, 'get_obs_doc_export_dlg', array($this, 'get_obs_doc_export_dlg'));
     Door43_Ajax_Helper::register_handler($controller, 'download_obs_template_docx', array($this, 'download_obs_template_docx'));
 }
开发者ID:richmahn,项目名称:Door43,代码行数:13,代码来源:ExportButtons.php

示例4: register

 function register(Doku_Event_Handler $controller)
 {
     global $conf;
     if ($conf['allowdebug']) {
         $controller->register_hook('TPL_ACT_RENDER', 'AFTER', $this, 'debug', array());
     }
 }
开发者ID:hefanbo,项目名称:dokuwiki-plugin-publish,代码行数:7,代码来源:debug.php

示例5: register

 /**
  * Registers a callback function for a given event
  *
  * @param Doku_Event_Handler $controller
  */
 function register(Doku_Event_Handler $controller)
 {
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, '_handle_tpl_act', array());
     $controller->register_hook('TPL_ACT_RENDER', 'BEFORE', $this, 'bookbar', array());
     $controller->register_hook('DOKUWIKI_STARTED', 'AFTER', $this, '_extendJSINFO');
     $controller->register_hook('TEMPLATE_PAGETOOLS_DISPLAY', 'BEFORE', $this, 'addbutton');
 }
开发者ID:a-gundy,项目名称:dokuwiki-plugin-bookcreator,代码行数:12,代码来源:action.php

示例6: register

 function register(Doku_Event_Handler $controller)
 {
     // Support given via AJAX
     $controller->register_hook('TOOLBAR_DEFINE', 'AFTER', $this, 'toolbar_add_button', array());
     $controller->register_hook('DOKUWIKI_STARTED', 'BEFORE', $this, 'metaheader_add_images', array());
     $controller->register_hook('POPUPVIEWER_DOKUWIKI_STARTED', 'BEFORE', $this, 'popupviewer_metaheader_add_images', array());
 }
开发者ID:godhelpjun,项目名称:dokuwiki-plugin-imageflow,代码行数:7,代码来源:action.php

示例7: register

 /**
  * Register the events
  */
 function register(Doku_Event_Handler $controller)
 {
     $scriptName = basename($_SERVER['PHP_SELF']);
     // should the lang be applied to UI?
     if ($this->getConf('translateui')) {
         switch ($scriptName) {
             case 'js.php':
                 $controller->register_hook('INIT_LANG_LOAD', 'BEFORE', $this, 'translation_js');
                 $controller->register_hook('JS_CACHE_USE', 'BEFORE', $this, 'translation_jscache');
                 break;
             case 'ajax.php':
                 $controller->register_hook('INIT_LANG_LOAD', 'BEFORE', $this, 'translate_media_manager');
                 break;
             case 'mediamanager.php':
                 $controller->register_hook('TPL_METAHEADER_OUTPUT', 'BEFORE', $this, 'setJsCacheKey');
                 break;
             default:
                 $controller->register_hook('TPL_METAHEADER_OUTPUT', 'BEFORE', $this, 'setJsCacheKey');
         }
     }
     if ($scriptName !== 'js.php' && $scriptName !== 'ajax.php') {
         $controller->register_hook('DOKUWIKI_STARTED', 'BEFORE', $this, 'translation_hook');
         $controller->register_hook('MEDIAMANAGER_STARTED', 'BEFORE', $this, 'translation_hook');
     }
     $controller->register_hook('SEARCH_QUERY_PAGELOOKUP', 'AFTER', $this, 'translation_search');
     $controller->register_hook('COMMON_PAGETPL_LOAD', 'AFTER', $this, 'page_template_replacement');
 }
开发者ID:splitbrain,项目名称:dokuwiki-plugin-translation,代码行数:30,代码来源:action.php

示例8: register

 public function register(Doku_Event_Handler &$controller)
 {
     $controller->register_hook('IO_WIKIPAGE_WRITE', 'AFTER', $this, 'handle_io_wikipage_write');
     $controller->register_hook('MEDIA_UPLOAD_FINISH', 'AFTER', $this, 'handle_media_upload');
     $controller->register_hook('MEDIA_DELETE_FILE', 'AFTER', $this, 'handle_media_deletion');
     $controller->register_hook('DOKUWIKI_DONE', 'AFTER', $this, 'handle_periodic_pull');
 }
开发者ID:daimrod,项目名称:dokuwiki-plugin-gitbacked,代码行数:7,代码来源:editcommit.php

示例9: register

 /**
  * register the eventhandlers
  */
 function register(Doku_Event_Handler $controller)
 {
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'handle_before', array());
     // allow other plugins to emit logging events
     $controller->register_hook('PLUGIN_LOGLOG_LOG', 'BEFORE', $this, 'handle_custom', array());
     // autologout plugin
     $controller->register_hook('ACTION_AUTH_AUTOLOGOUT', 'BEFORE', $this, 'handle_autologout', array());
 }
开发者ID:splitbrain,项目名称:dokuwiki-plugin-loglog,代码行数:11,代码来源:action.php

示例10: register

 public function register(Doku_Event_Handler $controller)
 {
     $controller->register_hook('TPL_METAHEADER_OUTPUT', 'BEFORE', $this, 'RenderMeta');
     $controller->register_hook('TPL_ACT_UNKNOWN', 'BEFORE', $this, 'tplMetaDataForm');
     //$controller->register_hook('TPL_ACT_RENDER','BEFORE',$this,'tplMetaDataButton');
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'ActPreprocessMeta');
     $controller->register_hook('TEMPLATE_PAGETOOLS_DISPLAY', 'BEFORE', $this, 'tplMetaDataMenuButton');
 }
开发者ID:cevro,项目名称:dokuwiki-plugin-social,代码行数:8,代码来源:action.php

示例11: register

 public function register(Doku_Event_Handler $controller)
 {
     //add to right menu
     $controller->register_hook('TEMPLATE_PAGETOOLS_DISPLAY', 'BEFORE', null, function (Doku_Event $event) {
         $event->data['items'][] = self::my_current_link_tpl(['do' => 'delete'], 'yk-delete', 'delete [D]', 'd', 'delete');
     });
     // ajax request
     $controller->register_hook('AJAX_CALL_UNKNOWN', 'BEFORE', $this, 'onAjaxCallUnknown', 'delete');
 }
开发者ID:yurii-github,项目名称:dokuwiki-plugin-yktools,代码行数:9,代码来源:activity.php

示例12: register

 public function register(Doku_Event_Handler &$controller)
 {
     if ($this->getConf(self::CONF_LOGIN_DS) === true) {
         $controller->register_hook('TPL_METAHEADER_OUTPUT', 'BEFORE', $this, '_hookcss');
     } else {
         $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'redirectToLoginHandler');
     }
     $controller->register_hook('HTML_LOGINFORM_OUTPUT', 'BEFORE', $this, 'handleLoginForm');
 }
开发者ID:MI-OSiRIS,项目名称:dokuwiki-shibboleth-auth,代码行数:9,代码来源:action.php

示例13: register

 /**
  * Register its handlers with the DokuWiki's event controller
  */
 function register(Doku_Event_Handler $controller)
 {
     // register custom edit buttons
     $controller->register_hook('HTML_SECEDIT_BUTTON', 'BEFORE', $this, 'secedit_button');
     // register our editor
     $controller->register_hook('HTML_EDIT_FORMSELECTION', 'BEFORE', $this, 'editform');
     // register preprocessing for accepting editor data
     // $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'handle_table_post');
     $controller->register_hook('PLUGIN_EDITTABLE_PREPROCESS_EDITOR', 'BEFORE', $this, 'handle_table_post');
 }
开发者ID:hefanbo,项目名称:edittable,代码行数:13,代码来源:editor.php

示例14: register

 /**
  * Register the events
  *
  * @param Doku_Event_Handler $controller
  */
 public function register(Doku_Event_Handler $controller)
 {
     /**
      * Submission button in top user menu bar
      */
     $controller->register_hook('TEMPLATE_USERTOOLS_DISPLAY', 'BEFORE', $this, 'addButton');
     /**
      * Submissions page content
      */
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'submissionsPageAction');
     $controller->register_hook('TPL_ACT_UNKNOWN', 'BEFORE', $this, 'submissionsPageContent');
     /**
      * Remove page cache after login
      */
     $controller->register_hook('AUTH_LOGIN_CHECK', 'AFTER', $this, 'removePageCache');
     /**
      * export to csv icon in submissions page
      */
     $controller->register_hook('TEMPLATE_PAGETOOLS_DISPLAY', 'BEFORE', $this, 'addCsvButton', array());
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'exportToCSV');
     /**
      * Ajax calls
      */
     $controller->register_hook('AJAX_CALL_UNKNOWN', 'BEFORE', $this, 'ajaxHandler');
 }
开发者ID:smmsadrnezh,项目名称:dokuwiki-plugin-judge,代码行数:30,代码来源:action.php

示例15: register

 /**
  * Register callback functions
  *
  * @param {Doku_Event_Handler} $controller DokuWiki's event controller object
  */
 public function register(Doku_Event_Handler $controller)
 {
     $controller->register_hook('DOKUWIKI_STARTED', 'BEFORE', $this, 'handle_start');
     $controller->register_hook('DOKUWIKI_STARTED', 'AFTER', $this, 'override_loadskin');
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'BEFORE', $this, 'handle_action_before');
     $controller->register_hook('ACTION_ACT_PREPROCESS', 'AFTER', $this, 'handle_action');
     $controller->register_hook('TPL_ACT_RENDER', 'BEFORE', $this, 'pre_render');
     $controller->register_hook('TPL_ACT_UNKNOWN', 'BEFORE', $this, 'unknown_action');
     $controller->register_hook('ACTION_SHOW_REDIRECT', 'BEFORE', $this, 'handle_redirect');
     $controller->register_hook('ACTION_HEADERS_SEND', 'BEFORE', $this, 'block_headers');
 }
开发者ID:sawachan,项目名称:dokuwiki_fastwiki,代码行数:16,代码来源:action.php


注:本文中的Doku_Event_Handler类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。