From b16734579035cc4d3160c766f874cdcbb544b1a2 Mon Sep 17 00:00:00 2001 From: oldperl Date: Tue, 15 Nov 2011 16:44:14 +0000 Subject: [PATCH] add: started with context help system add: initial readme file --- trunk/README | 88 ++++++++++++++++++++++++++++++++++ trunk/semmelstatzR.php | 41 +++++++++++----- trunk/semmelstatzR_startup.php | 14 ++++-- 3 files changed, 127 insertions(+), 16 deletions(-) create mode 100644 trunk/README diff --git a/trunk/README b/trunk/README new file mode 100644 index 0000000..2365052 --- /dev/null +++ b/trunk/README @@ -0,0 +1,88 @@ +/** + * file README + * + * @package SemmelstatzR + * @version $Rev$ + * @since 1.0.0 Beta + * @author SEM-Team + * @copyright (c)2011 SEM-Team + * @link http://sourceforge.net/projects/semmelstatz/ + * @license http://www.gnu.org/licenses/gpl-3.0.html + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * $Id$ + * + */ + +!!!Attention please !!! +This is just a Beta-release, so please don't use it in a productive enviroment because it's just for +testing purpose. +We assume no responsibility for any error caused by this release or loss of data by using this version. + +Welcome to semmelstatzReloaded (semmelstatzR). :) +SemmelstatzR is a statistic plugin for wordpress 2.8 and newer, based on the well known wp-plugin semmelstatz by +Andreas 'Redunzl' Mueller. + +** Installation ** + +Unzip and upload all files into your wordpress plugins folder. Log into wordpress admin area and choose +the plugins button in menu. If there were no problems you will find an entry for semmelstatzReloaded in +the pluginlist where you can activate semmelstatzR. SemmelstatzR will write some tables to your db. +If you have activeted the plugin, you will get a new submenu for semmelstatzR in the mainmenu. +Visit the Options-entry to do some configuration stuff. + +** Update/Upgrade ** + +First make a backup of your db, esspecially from your statz tables. Then go to pluginslist in the admin +area and deactivate the old semmelstatzR version. Delete or Move all files in the plugins/semmelstatzR folder, +then unzip package semmelstatzR with the new version and upload all files into folder plugins/semmelstatzR. +Now you may reactivate the plugin in the plugins admin area. +Done, have fun. :) + +** Usage ** + +In the future we will provide a webside at sf.net with documentation, faq and some tips. +The easiest was to lern how semmelstatzR can help you is going threw the menu in the admin area. + +** libraries, extensions, helpers and licenses ** + +pChart - a PHP Charting library +Version: 2.1.3 +License: http://www.gnu.org/licenses/gpl-3.0.html +Author: Jean-Damien POGOLOTTI +Homepage: http://www.pchart.net/ + +class upgrademe for wordpress (just the class, not as plugin) +Version: 0.2 +License: http://www.gnu.org/licenses/gpl.html +Author: Meglio (Anton Andriyevskyy) +Plugin URI: https://github.com/meglio/wp-upgrademe + +useragent ini file +Version: 20110628-02 +Homepage: http://user-agent-string.info + +We want to say thank you to the following people for ideas, help and testing + +silberling +Carsten + +** Translations ** + +english SEM-Team (default) +german SEM-Team + +If you want to translate semmelstatzR into a language not listed yet, we're pleased and we will +add your translation files (.mo and .po). \ No newline at end of file diff --git a/trunk/semmelstatzR.php b/trunk/semmelstatzR.php index 0c9bef0..dab6e33 100644 --- a/trunk/semmelstatzR.php +++ b/trunk/semmelstatzR.php @@ -79,19 +79,36 @@ if(is_admin() == true) { * @return void */ function semmelstatzR_menu() { - if (function_exists('add_menu_page')) { - add_menu_page('SemmelstatzR','SemmelstatzR', 'manage_statz', 'semmelstatzR/semmelstatzR-statz.php', '', plugins_url('semmelstatzR/img/statz_small.png')); - } - if (function_exists('add_submenu_page')) { - add_submenu_page('semmelstatzR/semmelstatzR-statz.php', semr_i18n('Current Statz'), semr_i18n('Current Statz'), 'manage_statz', 'semmelstatzR/semmelstatzR-statz.php'); - add_submenu_page('semmelstatzR/semmelstatzR-statz.php', semr_i18n('History'), semr_i18n('History'), 'manage_statz', 'semmelstatzR/semmelstatzR-history.php'); - add_submenu_page('semmelstatzR/semmelstatzR-statz.php', semr_i18n('Log'), semr_i18n('Log'), 'manage_statz', 'semmelstatzR/semmelstatzR-log.php'); - add_submenu_page('semmelstatzR/semmelstatzR-statz.php', semr_i18n('Database'), semr_i18n('Database'), 'manage_statz', 'semmelstatzR/semmelstatzR-database.php'); - add_submenu_page('semmelstatzR/semmelstatzR-statz.php', semr_i18n('Templates'), semr_i18n('Templates'), 'manage_statz', 'semmelstatzR/semmelstatzR-templates.php'); - add_submenu_page('semmelstatzR/semmelstatzR-statz.php', semr_i18n('Options'), semr_i18n('Options'), 'manage_statz', 'semmelstatzR/semmelstatzR-options.php'); - } + if (function_exists('add_menu_page')) { + add_menu_page('SemmelstatzR','SemmelstatzR', 'manage_statz', 'semmelstatzR/semmelstatzR-statz.php', '', plugins_url('semmelstatzR/img/statz_small.png')); + } + if (function_exists('add_submenu_page')) { + + global $semr_hook; + + $semr_hook['statz'] = add_submenu_page('semmelstatzR/semmelstatzR-statz.php', + semr_i18n('Current Statz'), semr_i18n('Current Statz'), + 'manage_statz', 'semmelstatzR/semmelstatzR-statz.php'); + $semr_hook['history'] = add_submenu_page('semmelstatzR/semmelstatzR-statz.php', + semr_i18n('History'), semr_i18n('History'), 'manage_statz', + 'semmelstatzR/semmelstatzR-history.php'); + $semr_hook['log'] = add_submenu_page('semmelstatzR/semmelstatzR-statz.php', + semr_i18n('Log'), semr_i18n('Log'), 'manage_statz', + 'semmelstatzR/semmelstatzR-log.php'); + $semr_hook['database'] = add_submenu_page('semmelstatzR/semmelstatzR-statz.php', + semr_i18n('Database'), semr_i18n('Database'), 'manage_statz', + 'semmelstatzR/semmelstatzR-database.php'); + $semr_hook['templates'] = add_submenu_page('semmelstatzR/semmelstatzR-statz.php', + semr_i18n('Templates'), semr_i18n('Templates'), 'manage_statz', + 'semmelstatzR/semmelstatzR-templates.php'); + $semr_hook['options'] = add_submenu_page('semmelstatzR/semmelstatzR-statz.php', + semr_i18n('Options'), semr_i18n('Options'), 'manage_statz', + 'semmelstatzR/semmelstatzR-options.php'); + } } add_action('admin_menu', 'semmelstatzR_menu'); + // include context help system + include SEMMELSTATZR_SRVPATH."includes/help/start.php"; ### end add toplevel adminmenu @@ -330,4 +347,4 @@ add_action('wp_dashboard_setup', 'sem_dashboardStatz_setup'); .sprintf(semr_i18np("%d Hit","%d Hits",$hits),$hits)." - " .sprintf(semr_i18np("%d Referer","%d Referers",$referers),$referers); } -?> +?> \ No newline at end of file diff --git a/trunk/semmelstatzR_startup.php b/trunk/semmelstatzR_startup.php index d9eacd6..0efa71a 100644 --- a/trunk/semmelstatzR_startup.php +++ b/trunk/semmelstatzR_startup.php @@ -46,7 +46,7 @@ */ ### constants define('SEMMELSTATZR_VERSION', '1.0.0 Beta'); -define('SEMMELSTATZR_SRVPATH', dirname(__FILE__)); +define('SEMMELSTATZR_SRVPATH', dirname(__FILE__).DIRECTORY_SEPARATOR); define('SEMMELSTATZR_HTML_RELPATH', WP_PLUGIN_URL.'/'.str_replace(basename( __FILE__),"",plugin_basename(__FILE__))); ### Deklaration der Tabellennamen @@ -68,9 +68,15 @@ if(!load_plugin_textdomain('semmelstatzR')) { load_plugin_textdomain('semmelstatzR',null,$plugin_dir.'/locale/'); } -include_once SEMMELSTATZR_SRVPATH.'/includes/functions.semr.php'; -include_once SEMMELSTATZR_SRVPATH.'/includes/functions.semr_template.php'; -include_once SEMMELSTATZR_SRVPATH.'/includes/class.upgrademe.php'; +// includes +include_once SEMMELSTATZR_SRVPATH.'includes/functions.semr.php'; +include_once SEMMELSTATZR_SRVPATH.'includes/functions.semr_template.php'; +include_once SEMMELSTATZR_SRVPATH.'includes/class.upgrademe.php'; + +// define some vars +$semr_hook = array(); + +// init upgrade stuff if(class_exists("Upgrademe")) { function semmelstatzR_upgrademe() { // will be changed to sf.net soon as website is ready