Changeset 1828085
- Timestamp:
- 02/23/2018 11:49:03 PM (8 years ago)
- Location:
- quick-recommend/trunk
- Files:
-
- 2 edited
-
quick-recommend.php (modified) (6 diffs)
-
readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
quick-recommend/trunk/quick-recommend.php
r1813251 r1828085 5 5 Plugin URI: http://oncapublishing.com/projects/quick-recommend 6 6 Description: Add a recommendation box to the bottom of your posts. Great for promoting books, movies, and other products when that is not the primary focus of your blog. 7 Version: 1. 18 Author: Shed Simas, Onça Publishing7 Version: 1.2 8 Author: Shed Simas, Onça Publishing 9 9 Author URI: http://oncapublishing.com 10 10 License: GPL2 … … 21 21 1.2 - register custom admin column data 22 22 1.3 - load external files to public website 23 1.4 - Advanced Custom Fields Settings 24 1.5 - register our custom menus 25 1.6 - load external files in WordPress admin 26 1.7 - register plugin options 27 1.8 - register activate/deactivate/uninstall functions 28 1.9 - register cotent filter 29 1.10 - register the relationship filter 23 1.4 - register our custom menus 24 1.5 - load external files in WordPress admin 25 1.6 - register plugin options 26 1.7 - register activate/deactivate/uninstall functions 27 1.8 - register cotent filter 28 1.9 - register the relationship filter 30 29 31 30 2. SHORTCODES … … 41 40 42 41 4. EXTERNAL SCRIPTS 43 4.1 - Include ACF42 4.1 - Advance Custom Fields settings 44 43 4.2 - qrec_public_scripts() 45 44 4.3 - loads external files into wordpress ADMIN … … 97 96 add_action('wp_enqueue_scripts', 'qrec_public_scripts'); 98 97 99 // 1.4 Advanced Custom Fields Settings 100 101 // 1.4.1 customize ACF path 102 add_filter('acf/settings/path', 'qrec_acf_settings_path'); 103 function qrec_acf_settings_path( $path ) { 104 // update path 105 $path = plugin_dir_path( __FILE__ ) .'lib/advanced-custom-fields/'; 106 // return 107 return $path; 108 } 109 // 1.4.2. customize ACF dir 110 add_filter('acf/settings/dir', 'qrec_acf_settings_dir'); 111 function qrec_acf_settings_dir( $dir ) { 112 // update path 113 $dir = plugin_dir_path( __FILE__ ) .'lib/advanced-custom-fields/'; 114 // return 115 return $dir; 116 } 117 // 1.4.3 hide ACF from admin bar 118 //add_filter('acf/settings/show_admin', '__return_false'); 119 if( !defined('ACF_LITE') ) define('ACF_LITE',true); 120 121 122 // 1.5 register our custom menus 98 // 1.4 register our custom menus 123 99 add_action('admin_menu', 'qrec_admin_menus'); 124 100 125 // 1. 6load external files in WordPress admin101 // 1.5 load external files in WordPress admin 126 102 add_action('admin_enqueue_scripts', 'qrec_admin_scripts'); 127 103 128 // 1. 7register plugin options104 // 1.6 register plugin options 129 105 add_action('admin_init', 'qrec_register_options'); 130 106 131 // 1. 8register activate/deactivate/uninstall functions107 // 1.7 register activate/deactivate/uninstall functions 132 108 add_action( 'admin_notices', 'qrec_check_wp_version' ); 133 109 register_uninstall_hook( __FILE__, 'qrec_uninstall_plugin' ); 134 110 135 // 1. 9register cotent filter111 // 1.8 register cotent filter 136 112 add_filter( 'the_content', 'qrec_show_rec' ); 137 113 138 // 1. 10register the relationship filter114 // 1.9 register the relationship filter 139 115 add_filter('acf/fields/relationship/result/name=qrec_recommendation', 'qrec_relationship_result', 10, 4); 140 116 … … 326 302 327 303 /* !4. EXTERNAL SCRIPTS */ 328 // 4.1 Include ACF 329 include_once( plugin_dir_path( __FILE__ ) .'lib/advanced-custom-fields/acf.php' ); 304 305 // 4.1 Advanced Custom Fields Settings 306 if( ! class_exists('acf') ) { 307 // 4.1.1 customize ACF path 308 add_filter('acf/settings/path', 'qrec_acf_settings_path'); 309 function qrec_acf_settings_path( $path ) { 310 // update path 311 $path = plugin_dir_path( __FILE__ ) .'lib/advanced-custom-fields/'; 312 // return 313 return $path; 314 } 315 // 4.1.2. customize ACF dir 316 add_filter('acf/settings/dir', 'qrec_acf_settings_dir'); 317 function qrec_acf_settings_dir( $dir ) { 318 // update path 319 $dir = plugin_dir_url( __FILE__ ) .'lib/advanced-custom-fields/'; 320 // return 321 return $dir; 322 } 323 324 // 4.1.3 Include ACF 325 include_once( plugin_dir_path( __FILE__ ) .'lib/advanced-custom-fields/acf.php' ); 326 327 328 // 4.1.4 hide ACF from admin bar 329 add_filter('acf/settings/show_admin', '__return_false'); 330 if( !defined('ACF_LITE') ) define('ACF_LITE',true); 331 } 330 332 331 333 // 4.2 loads external files into PUBLIC website … … 372 374 '4.9.1', 373 375 '4.9.2', 376 '4.9.3', 377 '4.9.4', 374 378 ); 375 379 -
quick-recommend/trunk/readme.txt
r1813250 r1828085 4 4 Tags: recommendation, recommendations, books, movies 5 5 Requires at least: 4.9 6 Tested up to: 4.9. 26 Tested up to: 4.9.4 7 7 Stable tag: trunk 8 8 Requires PHP: 5.2.4 … … 51 51 == Changelog == 52 52 53 = 1.2 = 54 * Fixed a compatibility issue when running other instances of Advance Custom Fields 55 * Removed WordPress version notice for up to 4.9.4 56 53 57 = 1.1 = 54 58 * Fixed an issue hiding the admin options page title from the page header … … 59 63 == Upgrade Notice == 60 64 65 = 1.2 = 66 * Fixed a compatibility issue when running other instances of Advance Custom Fields 67 61 68 = 1.1 = 62 69 * Fixed an issue hiding the admin options page title from the page header
Note: See TracChangeset
for help on using the changeset viewer.