Plugin Directory

Changeset 384401


Ignore:
Timestamp:
05/13/2011 01:25:25 PM (14 years ago)
Author:
lauweijie7715
Message:

3.0.3

Location:
cubepoints/trunk
Files:
6 added
1 deleted
8 edited

Legend:

Unmodified
Added
Removed
  • cubepoints/trunk/cp_admin.php

    r373336 r384401  
    66/** Admin pages */
    77function cp_admin() {
    8     add_menu_page('CubePoints', 'CubePoints', 8, 'cp_admin_manage', 'cp_admin_manage');
    9     add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Manage','cp'), __('Manage','cp'), 8, 'cp_admin_manage', 'cp_admin_manage');
    10     add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Configure','cp'), __('Configure','cp'), 8, 'cp_admin_config', 'cp_admin_config');
    11     add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Logs','cp'), __('Logs','cp'), 8, 'cp_admin_logs', 'cp_admin_logs');
     8    add_menu_page('CubePoints', 'CubePoints', 'manage_options', 'cp_admin_manage', 'cp_admin_manage');
     9    add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Manage','cp'), __('Manage','cp'), 'manage_options', 'cp_admin_manage', 'cp_admin_manage');
     10    add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Configure','cp'), __('Configure','cp'), 'manage_options', 'cp_admin_config', 'cp_admin_config');
     11    add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Logs','cp'), __('Logs','cp'), 'manage_options', 'cp_admin_logs', 'cp_admin_logs');
    1212    do_action('cp_admin_pages');
    13     add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Modules','cp'), __('Modules','cp'), 8, 'cp_admin_modules', 'cp_admin_modules');
     13    add_submenu_page('cp_admin_manage', 'CubePoints - ' .__('Modules','cp'), __('Modules','cp'), 'manage_options', 'cp_admin_modules', 'cp_admin_modules');
    1414}
    1515
  • cubepoints/trunk/cp_admin_config.php

    r373336 r384401  
    77{
    88    // handles form submissions
    9     if ($_POST['cp_admin_form_submit'] == 'Y') {
     9    if ( isset($_POST['cp_admin_form_submit']) && $_POST['cp_admin_form_submit'] == 'Y' ) {
    1010        $cp_topfilter = explode(',',str_replace(array("\n","\r"),'',$_POST['cp_topfilter']));
    1111        if(cp_topfilter==''){
  • cubepoints/trunk/cp_admin_modules.php

    r373336 r384401  
    77/** Make sure plugins get activated before page loads */
    88function cp_admin_module_process(){
    9     if($_POST['cp_module_activate']!=''&&$_POST['cp_module_name']!=''){
     9    if( isset($_POST['cp_module_activate']) && isset($_POST['cp_module_name']) ){
    1010        cp_module_activation_set( $_POST['cp_module_activate'] , true );
    1111    }
    12     if($_POST['cp_module_deactivate']!=''&&$_POST['cp_module_name']!=''){
     12    if( isset($_POST['cp_module_deactivate']) && isset($_POST['cp_module_name'])){
    1313        cp_module_activation_set( $_POST['cp_module_deactivate'] , false );
    1414    }
     
    1818/** Do activation and deactivation hooks */
    1919function cp_admin_module_hooks(){
    20     if($_POST['cp_module_activate']!=''&&$_POST['cp_module_name']!=''){
     20    if( isset($_POST['cp_module_activate']) && isset($_POST['cp_module_name'])){
    2121        do_action('cp_module_'.$_POST['cp_module_activate'].'_activate');
    2222    }
    23     if($_POST['cp_module_deactivate']!=''&&$_POST['cp_module_name']!=''){
     23    if( isset($_POST['cp_module_deactivate']) && isset($_POST['cp_module_name'])){
    2424        do_action('cp_module_'.$_POST['cp_module_deactivate'].'_deactivate');
    2525    }
     
    3636       
    3737        <?php
    38             if($_POST['cp_module_activate']!=''&&$_POST['cp_module_name']!=''){
     38            if( isset($_POST['cp_module_activate']) && isset($_POST['cp_module_name']) ){
    3939                echo '<div class="updated"><p><strong>'.__('Module', 'cp').' "'.$_POST['cp_module_name'].'"'.__(' activated','cp').'!</strong></p></div>';
    4040            }
    41             if($_POST['cp_module_deactivate']!=''&&$_POST['cp_module_name']!=''){
     41            if( isset($_POST['cp_module_deactivate']) && isset($_POST['cp_module_name']) ){
    4242                echo '<div class="updated"><p><strong>'.__('Module', 'cp').' "'.$_POST['cp_module_name'].'"'.__(' deactivated','cp').'!</strong></p></div>';
    4343            }
     
    6363            }
    6464            else{
    65                 $action ='<a href="javascipt:void(0);" onclick="alert(\''.__('This module cannot be deactivated through this page.', 'cp').'\n'.__('To deactive this module, remove it manually', 'cp').'.\')">'.__('Deactivate', 'cp').'</a>';
     65                $action ='<a href="javascript:void(0);" onclick="alert(\''.__('This module cannot be deactivated through this page.', 'cp').'\n'.__('To deactive this module, remove it manually', 'cp').'.\')">'.__('Deactivate', 'cp').'</a>';
    6666            }
    6767            if($m['plugin_url']!=''){
  • cubepoints/trunk/cp_api.php

    r373336 r384401  
    111111}
    112112
    113 if($_REQUEST['cp_api']!=''){
     113if( isset($_REQUEST['cp_api']) ){
    114114    add_action('init', 'cp_api');
    115115}
  • cubepoints/trunk/cp_hooks.php

    r373336 r384401  
    7676    $count = (int) $wpdb->get_var("select count(id) from `".CP_DB."` where `type`='post' and `data`=". $pid);
    7777    if($count==0){
    78         cp_points('post', cp_currentUser(), apply_filters('cp_post_points',get_option('cp_post_points')), $pid);
     78        cp_points('post', $uid, apply_filters('cp_post_points',get_option('cp_post_points')), $pid);
    7979    }
    8080}
  • cubepoints/trunk/cp_logs.php

    r373336 r384401  
    88
    99    global $wpdb;
     10 
     11  $q      = '';
     12  $limitq = ''; 
     13 
    1014    if($type!='all'){
    1115        $uid = (int) $type;
  • cubepoints/trunk/cubepoints.php

    r375874 r384401  
    44Plugin URI: http://cubepoints.com
    55Description: CubePoints is a point management system designed for Wordpress blogs. Users can earn points by posting comments on your site. To display user's points, just put <code>&lt;?php cp_displayPoints(); ?&gt;</code> in your template or activate the sidebar widget.
    6 Version: 3.0.2
     6Version: 3.0.1
    77Author: Jonathan Lau & Peter Zhang
    88Author URI: http://cubepoints.com
     
    1212
    1313/** Define constants */
    14 define('CP_VER', '3.0.2');
     14define('CP_VER', '3.0.1');
    1515define('CP_DB', $wpdb->base_prefix . 'cp');
    1616define('CP_PATH', WP_PLUGIN_URL.'/'.str_replace(basename( __FILE__),"",plugin_basename(__FILE__)));
     
    2020
    2121/** Loads the plugin's translated strings */
    22 load_plugin_textdomain('cp', PLUGINDIR.'/'.dirname(plugin_basename(__FILE__)).'/languages');
     22load_plugin_textdomain('cp', false, dirname(plugin_basename(__FILE__)).'/languages');
    2323
    2424/** Includes commons */
  • cubepoints/trunk/readme.txt

    r375874 r384401  
    44Tags: points, comments, post, admin, widget
    55Requires at least: 2.2
    6 Tested up to: 3.1.1
    7 Stable tag: 3.0.2
     6Tested up to: 3.1.2
     7Stable tag: 3.0.3
    88
    99CubePoints is a point management system designed for WordPress blogs.
     
    3030== Frequently Asked Questions ==
    3131
    32 = Why is the widget does not display correctly on my sidebar? =
     32= Where can I find additional help and support for this plugin? =
    3333
    34 Some themes are designed in a way that placing text in the sidebar looks weird. You might want to contact the designer of the theme or edit the widget manually as found in the documentation that came with the plugin.
     34You may visit the CubePoints Forum (http://cubepoints.com/forums/) for additional community help and support.
    3535
    3636= How do I activate other features? =
     
    4646
    4747== Upgrade Notice ==
     48
     49= 3.0.3 =
     50New module (YouTube Video) added. Minor bugfixes made and improved code for XHTML validation.
    4851
    4952= 3.0.2 =
     
    7275
    7376== Changelog ==
     77
     78**Version 3.0.3** *(May 13th, 2011)*
     79
     80+ [Change] Improvement to code to improve XHTML Validation and less E_NOTICE errors when WordPress is in debug mode
     81+ [Feature] New "YouTube Video" module added
     82+ [Bugfix] Fixed a small JS bug for the module management page
    7483
    7584**Version 3.0.2** *(April 22nd, 2011)*
Note: See TracChangeset for help on using the changeset viewer.