{"id":159,"date":"2008-03-20T22:24:49","date_gmt":"2008-03-20T14:24:49","guid":{"rendered":"http:\/\/lesterchan.net\/wordpress\/?p=159"},"modified":"2008-03-20T22:27:28","modified_gmt":"2008-03-20T14:27:28","slug":"my-plugins-and-wordpress-25","status":"publish","type":"post","link":"https:\/\/lesterchan.net\/wordpress\/2008\/03\/20\/my-plugins-and-wordpress-25\/","title":{"rendered":"My Plugins And WordPress 2.5"},"content":{"rendered":"<p>The current version of all my plugins will work on WordPress 2.5 <strong>PROVIDED<\/strong> you have upgraded your WordPress blog from WP 2.x to WP 2.5.<\/p>\n<p>If you are using a fresh copy of WordPress 2.5 together with my plugins, it WILL NOT work as WordPress 2.5 changes the <a href=\"http:\/\/codex.wordpress.org\/Migrating_Plugins_and_Themes#Activation_Global_Scope\">Activation Global Scope Of The Plugins<\/a>. In simpler terms, it means that upon activation of my plugins in WP-Admin, it will not create the tables needed by the respective plugins.<\/p>\n<p>To solve this problem temporary, do the following in <strong>polls.php<\/strong> (I am using WP-Polls as an example):<\/p>\n<p><strong>Find:<\/strong><\/p>\n<pre lang=\"php\" line=\"1\">\r\n$wpdb->pollsq = $table_prefix.'pollsq';\r\n$wpdb->pollsa = $table_prefix.'pollsa';\r\n$wpdb->pollsip = $table_prefix.'pollsip';\r\n<\/pre>\n<p><strong>Replace:<\/strong><\/p>\n<pre lang=\"php\" line=\"1\">\r\nglobal $wpdb;\r\n$wpdb->pollsq = $wpdb->prefix.'pollsq';\r\n$wpdb->pollsa = $wpdb->prefix.'pollsa';\r\n$wpdb->pollsip = $wpdb->prefix.'pollsip';\r\n<\/pre>\n<p>Note the addition of the &#8220;<strong>global $wpdb;<\/strong>&#8221; and the replacement of &#8220;$table_prefix&#8221; with &#8220;<strong>$wpdb->prefix<\/strong>&#8220;.<\/p>\n<p>I have updated WP-Polls, WP-ServerInfo, WP-Sticky and WP-UserOnline to work with WordPress 2.5. You can get them here at <a href=\"https:\/\/lesterchan.net\/wordpress\/downloads\/\">my downloads page<\/a> (do note that they are still in beta). Those plugins that end with a &#8220;Beta 2&#8221; means it will work for WordPress 2.5.<\/p>\n<p>Some of the updates are:<\/p>\n<ul>\n<li>Making sure that the styling, alignment and color of the plugin matches WordPress 2.5<\/li>\n<li>Fixes the &#8220;Activation Global Scope&#8221; issue<\/li>\n<li>Updated WP-Polls TinyMCE plugin to work with TinyMCE 3.0<\/li>\n<li>Added a summary of WP-ServerInfo as a Dashboard Widget<\/li>\n<li>Added a summary of WP-UserOnline in the Right Now Dashboard Widget<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The current version of all my plugins will work on WordPress 2.5 PROVIDED you have upgraded your WordPress blog from WP 2.x to WP 2.5. If you are using a fresh copy of WordPress 2.5 together with my plugins, it WILL NOT work as WordPress 2.5 changes the Activation Global Scope Of The Plugins. In &hellip; <a href=\"https:\/\/lesterchan.net\/wordpress\/2008\/03\/20\/my-plugins-and-wordpress-25\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;My Plugins And WordPress 2.5&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,8,13,20,15],"tags":[60,70,69,71],"class_list":["post-159","post","type-post","status-publish","format-standard","hentry","category-plugins","category-wp-polls","category-wp-serverinfo","category-wp-sticky","category-wp-useronline","tag-60","tag-prefix","tag-tinymce","tag-wpdb"],"views":17049,"_links":{"self":[{"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/posts\/159","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/comments?post=159"}],"version-history":[{"count":0,"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/posts\/159\/revisions"}],"wp:attachment":[{"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/media?parent=159"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/categories?post=159"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lesterchan.net\/wordpress\/wp-json\/wp\/v2\/tags?post=159"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}