开发者 | strider72 |
---|---|
更新时间 | 2016年4月28日 00:44 |
捐献地址: | 去捐款 |
PHP版本: | 2.6 及以上 |
WordPress版本: | 4.5.1 |
/wp-content/plugins/
) while keeping the file structure intact. You've done it right if you end up with a folder called "graceful-pull-quotes" inside your "plugins" folder.
Then activate it on your plugin management page.
Finally, go to the Pull-Quotes settings panel, (under the "Appearance" tab), and select your options. This step is optional, as the program works pretty well right out of the box, but you might want to at least previewing the different quote styles.wp_enqueue_script()
for preview scriptadd_ozh_adminmenu_icon
functionplugin_path => plugin_dir
| pq__() => p__()
| pq_e() => p_e()
http://codex.wordpress.org/WordPress_Coding_Standards
Update_options()
renamed to get_options()
style_name
setting with style_url
setting -- holds full URL$jspullquotes->plugin_path
add_actions()
renamed init()
. Now runs on "init" hook instead of running blind on plugin inclusion.$plugin_path
define into init()
set_defaults()
will now merge defaults with existing settings -- i.e. fill in new or missing options in a newly upgraded installcompare_versions()
-- Auto-run set_defaults on update without reactivateoption_name
in wp_options
table. Now "plugin_jspullquotes_settings
"settings_page()
instead of init()
)get_plugin_data()
-- no need to read the file twiceregister_activation_hook
outside of class. In init()
it was never being called__()
_e()
get_plugin_data()
set/reset_defaults()
functionsedit_themes
"_e()
function on Options screen to allow for translations