コード例 #1
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('idle_timer');
output_source('idle_timer');
/* settings page */
add_handler('settings', 'process_idle_time_setting', true, 'idle_timer', 'date', 'after');
add_output('settings', 'idle_time_setting', true, 'idle_timer', 'list_style_setting', 'after');
add_module_to_all_pages('handler', 'idle_time_check', true, 'idle_timer', 'load_user_data', 'after');
/* no-op poll */
add_handler('ajax_no_op', 'login', false, 'core');
add_handler('ajax_no_op', 'load_user_data', true, 'core');
add_handler('ajax_no_op', 'process_idle_time', true);
add_handler('ajax_no_op', 'date', true, 'core');
add_handler('ajax_no_op', 'http_headers', true, 'core');
return array('allowed_pages' => array('ajax_no_op'), 'allowed_post' => array('idle_time' => FILTER_VALIDATE_INT));
コード例 #2
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

/**
 * Core modules
 * @package modules
 * @subpackage core/functions
 */
require_once APP_PATH . 'modules/core/functions.php';
handler_source('core');
output_source('core');
/* homepage */
setup_base_page('home');
add_output('home', 'home_heading', true, 'core', 'content_section_start', 'after');
/* servers page */
setup_base_page('servers');
add_handler('servers', 'reload_folder_cookie', true, 'core', 'save_user_data', 'after');
add_output('servers', 'server_content_start', true, 'core', 'content_section_start', 'after');
add_output('servers', 'server_content_end', true, 'core', 'content_section_end', 'before');
/* compose */
setup_base_page('compose');
/* save settings */
setup_base_page('save');
add_handler('save', 'process_save_form', true, 'core', 'load_user_data', 'after');
add_output('save', 'save_form', true, 'core', 'content_section_start', 'after');
/* settings */
setup_base_page('settings');
add_handler('settings', 'process_language_setting', true, 'core', 'date', 'after');
add_handler('settings', 'process_list_style_setting', true, 'core', 'date', 'after');
add_handler('settings', 'process_timezone_setting', true, 'core', 'date', 'after');
add_handler('settings', 'process_unread_since_setting', true, 'core', 'date', 'after');
add_handler('settings', 'process_flagged_since_setting', true, 'core', 'date', 'after');
コード例 #3
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('nasa');
output_source('nasa');
/* APOD display */
setup_base_page('nasa_apod', 'core');
add_handler('nasa_apod', 'fetch_apod_content', true, 'nasa', 'load_user_data', 'after');
add_output('nasa_apod', 'apod_content', true, 'nasa', 'content_section_start', 'after');
/* folder list entry */
add_handler('ajax_hm_folders', 'nasa_folder_data', true, 'nasa', 'load_user_data', 'after');
add_output('ajax_hm_folders', 'nasa_folders', true, 'nasa', 'folder_list_content_start', 'before');
/* servers page */
add_handler('servers', 'nasa_folder_data', true, 'nasa', 'load_user_data', 'after');
add_output('servers', 'nasa_connect_section', true, 'nasa', 'server_content_end', 'before');
/* AJAX request to disconnect */
setup_base_ajax_page('ajax_nasa_disconnect', 'core');
add_handler('ajax_nasa_disconnect', 'process_nasa_connection', true, 'nasa', 'load_user_data', 'after');
/* AJAX request to connect */
setup_base_ajax_page('ajax_nasa_connect', 'core');
add_handler('ajax_nasa_connect', 'process_nasa_connection', true, 'nasa', 'load_user_data', 'after');
return array('allowed_pages' => array('nasa_apod', 'ajax_nasa_connect', 'ajax_nasa_disconnect'), 'allowed_post' => array('api_key' => FILTER_SANITIZE_STRING, 'nasa_disconnect' => FILTER_VALIDATE_BOOLEAN), 'allowed_get' => array('apod_date' => FILTER_SANITIZE_STRING), 'allowed_output' => array('nasa_action_status' => array(FILTER_VALIDATE_BOOLEAN, false)));
コード例 #4
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('account');
output_source('account');
/* create account page */
setup_base_page('create_account', 'core');
add_handler('create_account', 'process_create_account', true, 'account', 'login', 'after');
add_handler('create_account', 'check_internal_users', true, 'account', 'login', 'after');
add_output('create_account', 'create_form', true, 'account', 'content_section_start', 'after');
setup_base_page('change_password', 'core');
add_handler('change_password', 'process_change_password', true, 'account', 'load_user_data', 'after');
add_handler('change_password', 'check_internal_users', true, 'account', 'login', 'after');
add_output('change_password', 'change_password', true, 'account', 'content_section_start', 'after');
/* folder list link */
add_handler('ajax_hm_folders', 'check_internal_users', true, 'account', 'login', 'after');
add_output('ajax_hm_folders', 'create_account_link', true, 'account', 'settings_menu_end', 'before');
add_output('ajax_hm_folders', 'change_password_link', true, 'account', 'settings_menu_content', 'after');
/* input/output */
return array('allowed_pages' => array('create_account', 'change_password'), 'allowed_post' => array('create_username' => FILTER_SANITIZE_STRING, 'create_password' => FILTER_SANITIZE_STRING, 'create_password_again' => FILTER_SANITIZE_STRING, 'new_pass1' => FILTER_SANITIZE_STRING, 'new_pass2' => FILTER_SANITIZE_STRING, 'old_pass' => FILTER_SANITIZE_STRING, 'change_password' => FILTER_SANITIZE_STRING));
コード例 #5
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('contacts');
output_source('contacts');
/* contacts page */
setup_base_page('contacts', 'core');
add_handler('contacts', 'load_contacts', true, 'contacts', 'load_user_data', 'after');
add_handler('contacts', 'load_gmail_contacts', true, 'contacts', 'load_contacts', 'after');
add_handler('contacts', 'process_add_contact', true, 'contacts', 'load_contacts', 'after');
add_handler('contacts', 'process_edit_contact', true, 'contacts', 'load_contacts', 'after');
add_output('contacts', 'contacts_content_start', true, 'contacts', 'content_section_start', 'after');
add_output('contacts', 'contacts_content_add_form', true, 'contacts', 'contacts_content_start', 'after');
add_output('contacts', 'contacts_list', true, 'contacts', 'contacts_content_add_form', 'after');
add_output('contacts', 'gmail_contacts_list', true, 'contacts', 'contacts_list', 'after');
add_output('contacts', 'contacts_content_end', true, 'contacts', 'contacts_content_add_form', 'after');
add_output('ajax_hm_folders', 'contacts_page_link', true, 'contacts', 'logout_menu_item', 'before');
add_handler('compose', 'process_send_to_contact', true, 'contacts', 'save_user_data', 'before');
add_handler('ajax_imap_message_content', 'find_message_contacts', true, 'contacts', 'imap_message_content', 'after');
add_output('ajax_imap_message_content', 'add_message_contacts', true, 'contacts', 'filter_message_headers', 'after');
setup_base_ajax_page('ajax_add_contact', 'core');
add_handler('ajax_add_contact', 'load_contacts', true, 'contacts', 'load_user_data', 'after');
add_handler('ajax_add_contact', 'process_add_contact_from_message', true, 'contacts', 'load_contacts', 'after');
add_handler('ajax_add_contact', 'save_user_data', true, 'core', 'language', 'after');
setup_base_ajax_page('ajax_autocomplete_contact', 'core');
add_handler('ajax_autocomplete_contact', 'load_contacts', true, 'contacts', 'load_user_data', 'after');
add_handler('ajax_autocomplete_contact', 'load_imap_servers_from_config', true, 'imap', 'load_user_data', 'after');
add_handler('ajax_autocomplete_contact', 'autocomplete_contact', true, 'contacts', 'load_contacts', 'after');
add_output('ajax_autocomplete_contact', 'filter_autocomplete_list', true, 'contacts');
コード例 #6
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('calendar');
output_source('calendar');
/* calendar page */
setup_base_page('calendar', 'core');
add_handler('calendar', 'get_calendar_date', true, 'calendar', 'language', 'after');
add_output('calendar', 'calendar_content', true, 'calendar', 'content_section_start', 'after');
add_output('ajax_hm_folders', 'calendar_page_link', true, 'calendar', 'logout_menu_item', 'before');
return array('allowed_pages' => array('calendar'), 'allowed_get' => array('date' => FILTER_SANITIZE_STRING, 'view' => FILTER_SANITIZE_STRING));
コード例 #7
0
ファイル: setup.php プロジェクト: hanzubon/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('imap');
output_source('imap');
/* setup imap info for all pages for background unread checks */
add_module_to_all_pages('handler', 'load_imap_servers_from_config', true, 'imap', 'load_user_data', 'after');
add_module_to_all_pages('handler', 'imap_oauth2_token_check', true, 'imap', 'load_imap_servers_from_config', 'after');
add_module_to_all_pages('handler', 'load_imap_servers_for_message_list', true, 'imap', 'imap_oauth2_token_check', 'after');
add_module_to_all_pages('handler', 'add_imap_servers_to_page_data', true, 'imap', 'imap_oauth2_token_check', 'after');
/* add stuff to the info page */
add_output('info', 'display_imap_status', true, 'imap', 'server_status_start', 'after');
add_output('info', 'imap_server_ids', true, 'imap', 'page_js', 'before');
/* servers page data */
add_handler('servers', 'process_add_imap_server', true, 'imap', 'message_list_type', 'after');
add_handler('servers', 'save_imap_servers', true, 'imap', 'process_add_imap_server', 'after');
add_output('servers', 'add_imap_server_dialog', true, 'imap', 'server_content_start', 'after');
add_output('servers', 'display_configured_imap_servers', true, 'imap', 'add_imap_server_dialog', 'after');
add_output('servers', 'imap_server_ids', true, 'imap', 'page_js', 'before');
/* settings page data */
add_output('settings', 'imap_server_ids', true, 'imap', 'page_js', 'before');
/* compose page data */
add_output('compose', 'imap_server_ids', true, 'imap', 'page_js', 'before');
/* search page data */
add_handler('search', 'load_imap_servers_for_search', true, 'imap', 'message_list_type', 'after');
add_handler('search', 'imap_message_list_type', true, 'imap', 'message_list_type', 'after');
/* message list pages */
add_handler('message_list', 'imap_message_list_type', true, 'imap', 'message_list_type', 'after');
add_output('message_list', 'imap_custom_controls', true, 'imap', 'message_list_heading', 'before');
コード例 #8
0
ファイル: modules.php プロジェクト: GordonDiggs/hm3
 /**
  * @preserveGlobalState disabled
  * @runInSeparateProcess
  */
 public function test_output_source()
 {
     output_source('test');
     add_output('test', 'source_test', false);
     $this->assertEquals(array('source_test' => array('test', false)), Hm_Output_Modules::get_for_page('test'));
 }
コード例 #9
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('saved_searches');
output_source('saved_searches');
add_handler('ajax_save_search', 'login', false, 'core');
add_handler('ajax_save_search', 'load_user_data', true, 'core');
add_handler('ajax_save_search', 'save_search', true, 'core');
add_handler('ajax_save_search', 'language', true);
add_handler('ajax_save_search', 'date', true, 'core');
add_handler('ajax_save_search', 'http_headers', true, 'core');
add_output('ajax_save_search', 'filter_saved_search_result', true);
add_handler('ajax_update_search', 'login', false, 'core');
add_handler('ajax_update_search', 'load_user_data', true, 'core');
add_handler('ajax_update_search', 'update_search', true, 'core');
add_handler('ajax_update_search', 'language', true);
add_handler('ajax_update_search', 'date', true, 'core');
add_handler('ajax_update_search', 'http_headers', true, 'core');
add_output('ajax_update_search', 'filter_saved_search_result', true);
add_handler('ajax_delete_search', 'login', false, 'core');
add_handler('ajax_delete_search', 'load_user_data', true, 'core');
add_handler('ajax_delete_search', 'delete_search', true, 'core');
add_handler('ajax_delete_search', 'language', true);
add_handler('ajax_delete_search', 'date', true, 'core');
add_handler('ajax_delete_search', 'http_headers', true, 'core');
add_output('ajax_delete_search', 'filter_saved_search_result', true);
add_handler('ajax_hm_folders', 'saved_search_folder_data', true, 'saved_searches', 'load_user_data', 'after');
add_output('ajax_hm_folders', 'search_folders', true, 'saved_searches', 'folder_list_content_start', 'before');
add_handler('search', 'save_searches_data', true, 'saved_searches', 'load_user_data', 'after');
コード例 #10
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
/* dev resources and info page are only available in debug mode */
if (DEBUG_MODE) {
    /* setup sources */
    handler_source('developer');
    output_source('developer');
    /* info page */
    setup_base_page('info', 'core');
    add_handler('info', 'process_server_info', true, 'developer', 'load_user_data', 'after');
    add_output('info', 'info_heading', true, 'developer', 'content_section_start', 'after');
    add_output('info', 'server_information', true, 'developer', 'info_heading', 'after');
    add_output('info', 'server_status_start', true, 'developer', 'server_information', 'after');
    add_output('info', 'server_status_end', true, 'developer', 'server_status_start', 'after');
    add_output('info', 'config_map', true, 'developer', 'server_status_end', 'after');
    /* folder list */
    add_output('ajax_hm_folders', 'info_page_link', true, 'developer', 'settings_menu_end', 'before');
    add_output('ajax_hm_folders', 'developer_doc_link', true, 'developer', 'settings_menu_end', 'before');
    /* developer docs */
    setup_base_page('dev', 'core');
    add_output('dev', 'dev_content', true, 'developer', 'content_section_start', 'after');
    /* add pages */
    return array('allowed_pages' => array('info', 'dev'));
}
return array();
コード例 #11
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
/**
 * All requests should flow through the main index.php file of the program. The following
 * line insures this file is not loaded directly in the browser. All PHP files should
 * start with it. If someone tries to load the file directly it just quits immediately.
 */
if (!defined('DEBUG_MODE')) {
    die;
}
/**
 * These set the default sources for modules assigned in this file. It can be overridden
 * by the module assignment itself. The module system uses the source to know which PHP
 * files to include when servicing a given request. It should match the name of the module
 * set as used in the hm3.ini file, as well as the current directory name.
 */
handler_source('hello_world');
output_source('hello_world');
/**
 * Add an output module to the home page. The arguments to this function are:
 *
 * 'home'                   : The page identifier we want to attach a module to
 * 'hello_world_home_page'  : The module we want to attach
 * true                     : boolean to limit this module to logged in requests
 * 'hello_world'            : the module set of the module we want to attach
 * 'content_section_start'  : the module used as a basis to insert this one
 * 'after'                  : Either 'before' or 'after' the module in the prior argument
 *
 * This assignment will attach a module called "hello_world_home_page" to the output
 * processing of the home page. It will only trigger if the user is logged in, and is from
 * the module set "hello_world". It will be inserted into the home page processing after the
 * content_section_start module. See the setup.php file in the core module set for the default
 * modules included in a standard page. A corresponding output module for this needs to be
コード例 #12
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('nux');
output_source('nux');
/* servers page */
add_output('servers', 'quick_add_section', true, 'nux', 'server_content_start', 'after');
add_output('servers', 'quick_add_dialog', true, 'nux', 'quick_add_section', 'after');
add_handler('ajax_nux_service_select', 'login', false, 'core');
add_handler('ajax_nux_service_select', 'load_user_data', true, 'core');
add_handler('ajax_nux_service_select', 'setup_nux', true);
add_handler('ajax_nux_service_select', 'process_nux_service', true);
add_handler('ajax_nux_service_select', 'language', true, 'core');
add_handler('ajax_nux_service_select', 'date', true, 'core');
add_handler('ajax_nux_service_select', 'http_headers', true, 'core');
add_output('ajax_nux_service_select', 'filter_service_select', true);
add_handler('ajax_nux_add_service', 'login', false, 'core');
add_handler('ajax_nux_add_service', 'load_user_data', true, 'core');
add_handler('ajax_nux_add_service', 'setup_nux', true);
add_handler('ajax_nux_add_service', 'load_smtp_servers_from_config', true, 'smtp');
add_handler('ajax_nux_add_service', 'load_imap_servers_from_config', true, 'imap');
add_handler('ajax_nux_add_service', 'process_nux_add_service', true, 'nux');
add_handler('ajax_nux_add_service', 'save_user_data', true, 'core');
add_handler('ajax_nux_add_service', 'language', true, 'core');
add_handler('ajax_nux_add_service', 'date', true, 'core');
add_handler('ajax_nux_add_service', 'http_headers', true, 'core');
add_handler('home', 'load_pop3_servers_from_config', true, 'pop3', 'load_user_data', 'after');
add_handler('home', 'load_smtp_servers_from_config', true, 'smtp', 'load_user_data', 'after');
add_handler('home', 'load_feeds_from_config', true, 'feeds', 'load_user_data', 'after');
コード例 #13
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('pop3');
output_source('pop3');
/* add stuff to the info page */
add_handler('info', 'load_pop3_servers_from_config', true, 'pop3', 'language', 'after');
add_handler('info', 'add_pop3_servers_to_page_data', true, 'pop3', 'load_pop3_servers_from_config', 'after');
add_output('info', 'display_pop3_status', true, 'pop3', 'server_status_start', 'after');
add_output('info', 'pop3_server_ids', true, 'pop3', 'page_js', 'before');
/* message list page */
add_handler('message_list', 'load_pop3_servers_from_config', true, 'pop3', 'load_user_data', 'after');
add_handler('message_list', 'load_pop3_servers_for_message_list', true, 'pop3', 'load_pop3_servers_from_config', 'after');
add_handler('message_list', 'pop3_message_list_type', true, 'pop3', 'message_list_type', 'after');
/* message view page */
add_handler('message', 'load_pop3_servers_from_config', true, 'pop3', 'load_user_data', 'after');
add_handler('message', 'pop3_message_list_type', true, 'pop3', 'message_list_type', 'after');
add_handler('message', 'add_pop3_servers_to_page_data', true, 'pop3', 'load_pop3_servers_from_config', 'after');
/* servers page */
add_handler('servers', 'load_pop3_servers_from_config', true, 'pop3', 'language', 'after');
add_handler('servers', 'process_add_pop3_server', true, 'pop3', 'load_pop3_servers_from_config', 'after');
add_handler('servers', 'add_pop3_servers_to_page_data', true, 'pop3', 'process_add_pop3_server', 'after');
add_handler('servers', 'save_pop3_servers', true, 'pop3', 'add_pop3_servers_to_page_data', 'after');
add_output('servers', 'add_pop3_server_dialog', true, 'pop3', 'server_content_start', 'after');
add_output('servers', 'display_configured_pop3_servers', true, 'pop3', 'add_pop3_server_dialog', 'after');
/* settings page */
add_handler('settings', 'load_pop3_servers_from_config', true, 'pop3', 'language', 'after');
add_handler('settings', 'add_pop3_servers_to_page_data', true, 'pop3', 'load_pop3_servers_from_config', 'after');
add_handler('settings', 'process_pop3_limit_setting', true, 'pop3', 'save_user_settings', 'before');
コード例 #14
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('site');
output_source('site');
/* replace module just on the home page */
//replace_module('handler', 'http_headers', 'site_http_headers', 'home');
/* replace module on all pages */
//replace_module('handler', 'http_headers', 'site_http_headers', 'home');
/* allowed input */
return array('allowed_pages' => array(), 'allowed_cookie' => array(), 'allowed_server' => array(), 'allowed_get' => array(), 'allowed_post' => array());
コード例 #15
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

handler_source('history');
output_source('history');
setup_base_page('history', 'core');
add_output('history', 'history_heading', true, 'history', 'content_section_start', 'after');
add_output('ajax_hm_folders', 'history_page_link', true, 'history', 'logout_menu_item', 'before');
return array('allowed_pages' => array('history'));
コード例 #16
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('feeds');
output_source('feeds');
/* add stuff to the info page */
add_handler('info', 'load_feeds_from_config', true, 'feeds', 'language', 'after');
add_handler('info', 'add_feeds_to_page_data', true, 'feeds', 'load_feeds_from_config', 'after');
add_output('info', 'display_feeds_status', true, 'feeds', 'server_status_start', 'after');
add_output('info', 'feed_ids', true, 'feeds', 'page_js', 'before');
/* servers page data */
add_handler('servers', 'load_feeds_from_config', true, 'feeds', 'load_user_data', 'after');
add_handler('servers', 'process_add_feed', true, 'feeds', 'load_feeds_from_config', 'after');
add_handler('servers', 'add_feeds_to_page_data', true, 'feeds', 'process_add_feed', 'after');
add_handler('servers', 'save_feeds', true, 'feeds', 'add_feeds_to_page_data', 'after');
add_output('servers', 'add_feed_dialog', true, 'feeds', 'server_content_start', 'after');
add_output('servers', 'display_configured_feeds', true, 'feeds', 'add_feed_dialog', 'after');
add_output('servers', 'feed_ids', true, 'feeds', 'page_js', 'before');
/* search */
add_handler('search', 'load_feeds_from_config', true, 'feeds', 'load_user_data', 'after');
add_handler('search', 'load_feeds_for_search', true, 'feeds', 'load_feeds_from_config', 'after');
add_handler('search', 'feed_list_type', true, 'feeds', 'message_list_type', 'after');
/* settings page */
add_handler('settings', 'process_unread_feeds_setting', true, 'feeds', 'save_user_settings', 'before');
add_handler('settings', 'process_feed_limit_setting', true, 'feeds', 'save_user_settings', 'before');
add_handler('settings', 'process_feed_since_setting', true, 'feeds', 'save_user_settings', 'before');
add_output('settings', 'unread_feeds_included', true, 'feeds', 'unread_source_max_setting', 'after');
add_output('settings', 'start_feed_settings', true, 'feeds', 'end_settings_form', 'before');
add_output('settings', 'feed_since_setting', true, 'feeds', 'start_feed_settings', 'after');
コード例 #17
0
ファイル: setup.php プロジェクト: R-J/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('wordpress');
output_source('wordpress');
add_handler('message', 'wordpress_list_type', true, 'wordpress', 'message_list_type', 'after');
add_handler('message_list', 'wp_load_sources', true, 'wordpress', 'load_user_data', 'after');
add_handler('message_list', 'wordpress_list_type', true, 'wordpress', 'message_list_type', 'after');
add_handler('ajax_hm_folders', 'wordpress_folders_data', true, 'wordpress', 'load_user_data', 'after');
add_output('ajax_hm_folders', 'wordpress_folders', true, 'wordpress', 'folder_list_content_start', 'before');
add_handler('servers', 'setup_wordpress_connect', true, 'wordpress', 'load_user_data', 'after');
add_handler('servers', 'wordpress_disconnect', true, 'wordpress', 'setup_wordpress_connect', 'after');
add_output('servers', 'wordpress_connect_section', true, 'wordpress', 'server_content_end', 'before');
add_handler('ajax_message_action', 'wordpress_list_type', true, 'wordpress', 'load_user_data', 'after');
add_handler('ajax_message_action', 'wordpress_msg_action', true, 'wordpress', 'wordpress_list_type', 'after');
add_handler('home', 'process_wordpress_authorization', true, 'wordpress', 'load_user_data', 'after');
add_handler('ajax_wordpess_notifications', 'login', false, 'core');
add_handler('ajax_wordpess_notifications', 'load_user_data', true, 'core');
add_handler('ajax_wordpess_notifications', 'message_list_type', true, 'core');
add_handler('ajax_wordpess_notifications', 'language', true, 'core');
add_handler('ajax_wordpess_notifications', 'wordpress_list_type', true, 'core');
add_handler('ajax_wordpess_notifications', 'wp_notification_data', true);
add_handler('ajax_wordpess_notifications', 'date', true, 'core');
add_handler('ajax_wordpess_notifications', 'http_headers', true, 'core');
add_output('ajax_wordpess_notifications', 'filter_wp_notification_data', true);
add_handler('ajax_wp_notice_display', 'login', false, 'core');
add_handler('ajax_wp_notice_display', 'load_user_data', true, 'core');
add_handler('ajax_wp_notice_display', 'language', true, 'core');
add_handler('ajax_wp_notice_display', 'get_wp_notice_data', true);
コード例 #18
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('profiles');
output_source('profiles');
/* profiles page */
setup_base_page('profiles', 'core');
add_output('profiles', 'profile_content', true, 'profiles', 'content_section_start', 'after');
add_output('ajax_hm_folders', 'profile_page_link', true, 'profiles', 'settings_menu_end', 'before');
return array('allowed_pages' => array('profiles'));
コード例 #19
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('swipe_2fa');
output_source('swipe_2fa');
add_module_to_all_pages('handler', 'swipe_2fa_check', true, 'swipe_2fa', 'save_user_data', 'after');
add_module_to_all_pages('output', 'swipe_2fa_dialog', true, 'swipe_2fa', 'header_start', 'before');
return array('allowed_post' => array('sms_number' => FILTER_SANITIZE_STRING, '2fa_sms_response' => FILTER_SANITIZE_STRING));
コード例 #20
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('github');
output_source('github');
add_handler('ajax_hm_folders', 'github_folders_data', true, 'github', 'load_user_data', 'after');
add_output('ajax_hm_folders', 'github_folders', true, 'github', 'folder_list_content_start', 'before');
add_module_to_all_pages('handler', 'github_list_type', true, 'github', 'message_list_type', 'after');
add_handler('servers', 'setup_github_connect', true, 'github', 'load_user_data', 'after');
add_handler('servers', 'github_disconnect', true, 'github', 'setup_github_connect', 'after');
add_handler('servers', 'github_process_add_repo', true, 'github', 'github_disconnect', 'after');
add_handler('servers', 'github_process_remove_repo', true, 'github', 'github_process_add_repo', 'after');
add_output('servers', 'github_connect_section', true, 'github', 'server_content_end', 'before');
add_output('servers', 'github_add_repo', true, 'github', 'github_connect_section', 'after');
add_handler('home', 'process_github_authorization', true, 'github', 'load_user_data', 'after');
add_handler('ajax_message_action', 'github_message_action', true, 'github', 'load_user_data', 'after');
add_handler('ajax_github_data', 'login', false, 'core');
add_handler('ajax_github_data', 'load_user_data', true, 'core');
add_handler('ajax_github_data', 'language', true, 'core');
add_handler('ajax_github_data', 'github_list_data', true);
add_handler('ajax_github_data', 'close_session_early', true, 'core');
add_handler('ajax_github_data', 'date', true, 'core');
add_handler('ajax_github_data', 'http_headers', true, 'core');
add_output('ajax_github_data', 'filter_github_data', true);
add_handler('info', 'load_github_repos', true, 'github', 'language', 'after');
add_output('info', 'display_github_status', true, 'github', 'server_status_start', 'after');
add_handler('ajax_github_event_detail', 'login', false, 'core');
add_handler('ajax_github_event_detail', 'load_user_data', true, 'core');
add_handler('ajax_github_event_detail', 'language', true, 'core');
コード例 #21
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('smtp');
output_source('smtp');
add_module_to_all_pages('handler', 'smtp_default_server', true, 'smtp', 'load_user_data', 'after');
add_handler('compose', 'load_smtp_servers_from_config', true, 'smtp', 'load_user_data', 'after');
add_handler('compose', 'add_smtp_servers_to_page_data', true, 'smtp', 'load_smtp_servers_from_config', 'after');
add_handler('compose', 'process_compose_form_submit', true, 'smtp', 'load_smtp_servers_from_config', 'after');
add_output('compose', 'compose_form', true, 'smtp', 'content_section_start', 'after');
/* servers page */
add_handler('servers', 'load_smtp_servers_from_config', true, 'smtp', 'language', 'after');
add_handler('servers', 'process_add_smtp_server', true, 'smtp', 'load_smtp_servers_from_config', 'after');
add_handler('servers', 'add_smtp_servers_to_page_data', true, 'smtp', 'process_add_smtp_server', 'after');
add_handler('servers', 'save_smtp_servers', true, 'smtp', 'add_smtp_servers_to_page_data', 'after');
add_output('servers', 'add_smtp_server_dialog', true, 'smtp', 'server_content_start', 'after');
add_output('servers', 'display_configured_smtp_servers', true, 'smtp', 'add_smtp_server_dialog', 'after');
add_handler('settings', 'process_compose_type', true, 'smtp', 'save_user_settings', 'before');
add_output('settings', 'compose_type_setting', true, 'smtp', 'start_general_settings', 'after');
/* ajax server setup callback data */
add_handler('ajax_smtp_debug', 'login', false, 'core');
add_handler('ajax_smtp_debug', 'load_user_data', true, 'core');
add_handler('ajax_smtp_debug', 'load_smtp_servers_from_config', true);
add_handler('ajax_smtp_debug', 'add_smtp_servers_to_page_data', true);
add_handler('ajax_smtp_debug', 'smtp_connect', true);
add_handler('ajax_smtp_debug', 'smtp_delete', true);
add_handler('ajax_smtp_debug', 'smtp_forget', true);
add_handler('ajax_smtp_debug', 'smtp_save', true);
add_handler('ajax_smtp_debug', 'save_smtp_servers', true);
コード例 #22
0
ファイル: setup.php プロジェクト: GordonDiggs/hm3
<?php

if (!defined('DEBUG_MODE')) {
    die;
}
handler_source('themes');
output_source('themes');
add_module_to_all_pages('handler', 'load_theme', true, 'themes', 'load_user_data', 'after');
add_module_to_all_pages('output', 'theme_css', true, 'themes', 'header_css', 'after');
add_handler('ajax_hm_folders', 'load_theme', true, 'themes', 'load_user_data', 'after');
add_handler('ajax_imap_folder_expand', 'load_theme', true, 'themes', 'load_user_data', 'after');
add_handler('settings', 'process_theme_setting', true, 'themes', 'save_user_settings', 'before');
add_output('settings', 'theme_setting', true, 'feeds', 'language_setting', 'after');
return array('allowed_post' => array('theme_setting' => FILTER_SANITIZE_STRING));