How Do I Use jQuery UI In My Plugin

Given that all of the libraries you need for the datepicker are bundled with WordPress and are registered with all of the appropriate dependencies, all you really need to do is: function enqueue_my_scripts_wpse_97533() { wp_enqueue_script(‘jquery-ui-datepicker’); } add_action(‘wp_enqueue_scripts’,’enqueue_my_scripts_wpse_97533′); If you then look at the source of the page you will see that jQuery, jQuery-UI, and jQuery-UI-Datepicker … Read more

what’s the meaning of the field wp_capabilities in table wp_usermeta

The wp_capabilities saves the value as serilized array, you can try it in your php or for this example here: http://blog.tanist.co.uk/files/unserialize/. The Code: a:1:{s:13:”administrator”;b:1;} Is: Array ( [administrator] => 1 ) Meaning the user is an administrator. You can add new roles to the database by running the function add_role, and only run it once!

how to create child WordPress plugin

the Best way to do this is have your X plugin made with its own hooks for actions and filters so new plugins (in your case Y) could interact with plugin X’s functions and data. Defining your own hooks is fairly easy and simple. Action Hook from the codex: Actions are the hooks that the … Read more

Settings API updated messages won’t show if custom admin page not hooked into add_options_page()

Thanks Chip (excellent Settings API tutorial) and t31os (great snippet of code for quick testing) for both your suggestions. I did some further digging and found that the default messages can indeed be displayed if I hook into any menu but only if the function settings_errors() is called. For example, modifying t31os code as follows: … Read more

How to check uniqueness of plugin prefix?

You can use the WordPres Plugin Directory Slurper shell script by Mark Jaquith to download the the most recent version of all plugins from the WordPress.org repo. Once the plugins have been downloaded, you can grep for the plugin/hook prefix you want to check, e.g.: grep -r –include=*.php ‘wpseo_’ ./ Unzip the WordPres Plugin Directory … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)