Changeset 519490
- Timestamp:
- 03/15/2012 06:49:17 PM (14 years ago)
- Location:
- admin-dashboard-site-notes
- Files:
-
- 18 added
- 1 deleted
- 3 edited
-
tags/1.3.2 (added)
-
tags/1.3.2/admin-scripts.js (added)
-
tags/1.3.2/admin-styles-1.3.0.css (added)
-
tags/1.3.2/class.DSNManager.php (added)
-
tags/1.3.2/dashboard-site-notes.php (added)
-
tags/1.3.2/languages (added)
-
tags/1.3.2/languages/admin-dashboard-site-notes.pot (added)
-
tags/1.3.2/languages/dsnmanager-it_IT.mo (added)
-
tags/1.3.2/languages/dsnmanager-it_IT.po (added)
-
tags/1.3.2/languages/dsnmanager-nl_NL.mo (added)
-
tags/1.3.2/languages/dsnmanager-nl_NL.po (added)
-
tags/1.3.2/license.txt (added)
-
tags/1.3.2/readme.txt (added)
-
tags/1.3.2/screenshot-1.png (added)
-
tags/1.3.2/screenshot-2.png (added)
-
tags/1.3.2/screenshot-3.png (added)
-
tags/1.3.2/screenshot-4.png (added)
-
tags/1.3.2/screenshot-5.png (added)
-
trunk/admin-styles.css (deleted)
-
trunk/class.DSNManager.php (modified) (13 diffs)
-
trunk/dashboard-site-notes.php (modified) (1 diff)
-
trunk/readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
admin-dashboard-site-notes/trunk/class.DSNManager.php
r517859 r519490 4 4 class DSNManager { 5 5 private $shortcode = "sitenote"; // if changed, also change in dashboard-site-notes.php 6 private $plugin_version = "1.3. 0";6 private $plugin_version = "1.3.2"; 7 7 private $plugin_id = 'dsnmanager'; 8 8 private $plugin_stylesheet_id = 'dsnmanager_css'; … … 99 99 100 100 // if there's no version set in the database, it's a pre-1.3 version, so run the "upgrade" code and then create the version 101 if(!isset($this->options['version']) || version_compare($this->options['version'], '1.3.1', '<')) { 101 if(!isset($this->options['version']) || version_compare($this->options['version'], '1.3', '<')) { 102 // do the version upgrade now; none of these updates are critical and if they fail we 103 // don't want to bring the site to a crawl like the previous version. 104 $this->options['version'] = $this->plugin_version; 105 update_option($this->plugin_id, $this->options); 106 $this->options = $this->get_all_options(); 107 102 108 // set instruction_manual to the opposite of instructions_exclude and rename it 103 109 $sql = " … … 107 113 "; 108 114 $updated_rows = $wpdb->query($sql); 109 $this->options['updated_rows_instruction_manual'] = $updated_rows;110 111 $this->options['version'] = $this->plugin_version;112 update_option($this->plugin_id, $this->options);113 115 114 116 // Create "admin_notice" meta key for each existing dsn_note, since it's now required … … 120 122 "; 121 123 $updated_admin_notices = $wpdb->query($sql); 122 $this->options['updated_admin_notices'] = $updated_admin_notices;123 124 124 125 // Create "contextual_help" meta key for each existing dsn_note … … 130 131 "; 131 132 $updated_admin_notices = $wpdb->query($sql); 132 $this->options['updated_admin_notices'] = $updated_admin_notices;133 133 134 134 // rename "loc_dashboard" to "dashboard_widget" in anticipation of having a dashboard page location … … 143 143 // delete all meta keys attached incorrectly to non-dsn_note post types 144 144 // to minimize risk of deleting meta keys created by other plugins, we'll be as specific as possible rather than just using '_dsn_%' 145 $old_prefix = '_dsn_'; // hardcoded to _dsn_ because it was used in prior versions 146 $pre_role = $old_prefix . "role_"; // role meta keys 147 $pre_loc = $old_prefix . "loc_"; // locations meta keys 148 $pre_hide = $old_prefix . "hide_title"; // hide_title meta keys 149 $pre_instr = $old_prefix . "instructions_exclude"; // instructions_exclude meta keys 150 145 $prefix = '_dsn_'; // prefix hardcoded to _dsn_ because it was used in all previous versions 146 $pre_role = $prefix . "role_"; // role meta keys 147 $pre_loc = $prefix . "loc_"; // locations meta keys 148 $pre_hide = $prefix . "hide_title"; // hide_title meta keys 149 $pre_instr = $prefix . "instructions_exclude"; // instructions_exclude meta keys 151 150 $sql = " 152 151 DELETE FROM wppm … … 159 158 WHERE ID = wppm.post_id AND wpp.post_type = 'dsn_note')"; 160 159 $deleted_rows = $wpdb->query($sql); 161 $this->options['deleted_rows_metabug'] = $deleted_rows;162 163 // NOTE: for future versions, make sure to allow previous scripts to run too in case someone skips an update. watch out about updating version in here.164 // store this version as the current plugin version in the options165 $this->options['version'] = $this->plugin_version;166 update_option($this->plugin_id, $this->options);167 160 } 168 161 } … … 614 607 } 615 608 // check nonce 616 $nonce_id = $this->nonce_id;617 if(!wp_verify_nonce($_POST[$nonce_id],$nonce_id)) {618 return $post_id;619 }609 //$nonce_id = $this->nonce_id; 610 //if(!wp_verify_nonce($_POST[$nonce_id],$nonce_id)) { 611 // return $post_id; 612 //} 620 613 621 614 if(is_array($_POST) && count($_POST)) { … … 701 694 $output .= "</div>"; 702 695 696 703 697 // add misc options 704 698 $output .= "<div id='dsn_meta_other'>"; // open #dsn_meta_other … … 829 823 830 824 ///////// 825 // 831 826 // OPTIONS PAGE SECTION 827 // 832 828 ///////// 833 829 … … 854 850 'manual_title' => __("Site Instruction Manual", DSNMANAGER_TEXTDOMAIN), 855 851 'manual_nav' => __("Site Instructions", DSNMANAGER_TEXTDOMAIN), 852 'version'=>false, 856 853 ); 857 854 $roles = $this->get_roles(); … … 894 891 add_settings_section($section_roles, __('Permissions', DSNMANAGER_TEXTDOMAIN), array($this,'settings_section_roles_description'), $this->plugin_id); 895 892 893 // TODO: add_settings_field('support_author',__('Add author name support'), array($this,'input_checkbox'), $this->plugin_id, 'plugin_main', array('id'=>'support_author')); 894 // TODO: add_settings_field('support_thumbnail',__('Add thumbnail support'), array($this,'input_checkbox'), $this->plugin_id, 'plugin_main', array('id'=>'support_thumbnail')); 896 895 $cb_check = array($this,'input_checkbox'); 897 896 $cb_text = array($this,'input_textfield'); … … 997 996 } 998 997 ///////// 998 // 999 999 // END OPTIONS PAGE SECTION 1000 // 1000 1001 ///////// 1001 1002 -
admin-dashboard-site-notes/trunk/dashboard-site-notes.php
r517849 r519490 4 4 Plugin URI: http://innerdvations.com/plugins/admin-dashboard-notes/ 5 5 Description: Create site notes to appear either on the dashboard or at the top of various admin pages. 6 Version: 1.3 6 Version: 1.3.2 7 7 Author: Ben Irvin 8 8 Author URI: http://innerdvations.com/ 9 Tags: instructions, manual, contextual help, help tab, admin notice, notes9 Tags: instructions, manual, admin, notes, notices, instruction manual 10 10 Wordpress URI: http://wordpress.org/extend/plugins/admin-dashboard-site-notes/ 11 11 License: GPLv3 -
admin-dashboard-site-notes/trunk/readme.txt
r517852 r519490 5 5 Requires at least: 3.0 6 6 Tested up to: 3.3.1 7 Stable tag: 1.3 7 Stable tag: 1.3.2 8 8 9 Add notes as admin notices , contextual help tabs, in an instruction manual, and/or placed in a dashboard widget.9 Add notes as admin notices in contextual help tabs, as well as compile them into an instruction manual. 10 10 11 11 == Description == 12 12 13 Add notes as admin notices , contextual help tabs, in an instruction manual, and/or placed in a dashboard widget.13 Add notes as admin notices in contextual help tabs, as well as compile them into an instruction manual or placed in a dashboard widget. 14 14 15 This plugin is intended to build instructions into a site for clients, although it can be configured as a general purpose tool to leave temporary notes to any group on your site that has admin access.15 This is intended to build instructions into a site for clients, so it is focused on providing abilities only to the highest role of user available on a site, although it can be configured as a general purpose tool to leave temporary notes to any group on your site that has admin access. 16 16 17 17 == Installation == … … 50 50 = What is planned for future versions? = 51 51 Here are features planned for future versions (probably released about every 2-3 months): 52 53 52 * 1.4: add ability to put notes in the admin bar 54 53 * 1.4: add warnings if a note is created that can't be seen anywhere (no role or location selected) … … 80 79 81 80 == Changelog == 81 = 1.3.1 = 82 * bugfix: fixed plugin upgrade script that caused tons of slow pages 83 82 84 = 1.3 = 83 85 * feature: ability to add notes to the contextual help tab 86 * feature: shortcode 'sitenote' or can be renamed with define('DSN_SHORTCODE','yourshortcode'); 84 87 * feature: 'attachment' type now works on WP Media pages 85 88 * feature: 'revision' type now works on WP revision page 86 * feature: shortcode 'sitenote' or can be renamed with define('DSN_SHORTCODE','yourshortcode');87 89 * feature: restructured so that plugin memory/cpu footprint on non-admin pages now extremely tiny 88 90 * change: 'exclude from instructions' has been replaced with a new instruction manual location. existing notes updated on upgrade.
Note: See TracChangeset
for help on using the changeset viewer.