Changeset 1672335
- Timestamp:
- 06/07/2017 08:25:23 AM (9 years ago)
- Location:
- booklaunch/trunk
- Files:
-
- 2 edited
-
booklaunch.php (modified) (4 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
booklaunch/trunk/booklaunch.php
r1126672 r1672335 4 4 Plugin URI: https://booklaunch.io 5 5 Description: A plugin that integrates your Booklaunch page as a page template on your Wordpress website. 6 Version: 1.0. 46 Version: 1.0.5 7 7 Author: The Booklaunch Team 8 8 Author URI: https://booklaunch.io … … 26 26 27 27 } 28 28 29 29 /** 30 30 * Initializes the plugin by setting filters and administration functions. … … 34 34 $this->templates = array(); 35 35 36 37 // Adds a filter to the attributes metabox to inject template into the cache. 38 add_filter( 39 'page_attributes_dropdown_pages_args', 40 array( $this, 'register_booklaunch_templates' ) 41 ); 42 36 // Add a filter to the attributes metabox to inject template into the cache. 37 if ( version_compare( floatval( get_bloginfo( 'version' ) ), '4.7', '<' ) ) { 38 39 // 4.6 and older 40 add_filter( 41 'page_attributes_dropdown_pages_args', 42 array( $this, 'register_booklaunch_templates' ) 43 ); 44 45 } else { 46 47 // Add a filter to the wp 4.7 version attributes metabox 48 add_filter( 49 'theme_page_templates', array( $this, 'add_new_template' ) 50 ); 51 52 } 43 53 44 54 // Adds filter to the save post to inject out template into the page cache … … 61 71 } 62 72 73 /** 74 * Adds our template to the page dropdown for v4.7+ 75 * 76 */ 77 public function add_new_template( $posts_templates ) { 78 $posts_templates = array_merge( $posts_templates, $this->templates ); 79 return $posts_templates; 80 } 63 81 64 82 /** -
booklaunch/trunk/readme.txt
r1126672 r1672335 4 4 Tags: booklaunch 5 5 Requires at least: 3.0 6 Tested up to: 4. 17 Stable tag: 1.0. 46 Tested up to: 4.7.5 7 Stable tag: 1.0.5 8 8 License: GPLv2 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 57 57 * Make sure the Booklaunch Options are toggled on in the editor's "Screen Options" tab. 58 58 59 = Why don't I see "Booklaunch Page" dropdown? = 60 61 Make sure to update your Booklaunch plugin from the Wordpress dashboard. Wordpress 4.7+ is not compatible with old versions of this plugin. 62 59 63 == Changelog == 64 65 66 = 1.0.5 = 67 * Plugin now works with Wordpress 4.7+ 60 68 61 69 = 1.0.4 =
Note: See TracChangeset
for help on using the changeset viewer.