wordpress snippets last updated   : August 18, 2014
we now have 638 snippets

Add plugin settings link to plugins list table

wordpress snippet

When building a plugin that has its own settings page, it’s often handy to create a link to the settings page straight from the Plugins page in the dashboard – this saves users the time it takes to find where exactly your plugin appears in the admin menu. Here is a simple code snippet that creates the settings link for you – all you need to do is set the link to point to the right place. This code must be placed in your plugin’s index file.

read more

Disable theme, plugin editor and plugin, core updates

wordpress snippet

Adding the first line to your wordpress wp-config.php file will disable theme and plugin editor. Adding the second line to your wordpress wp-config.php file will disable plugin and core updates.

read more

Disable plugin deactivation for specific plugins

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will enable you to remove the deactivate link from specific plugins. This will help you stop clients from deactivating core plugins while still providing access.

read more

Check if a plugin is active

wordpress snippet

Adding this snippet to your wordpress theme will return true if the specified plugin is active. You will need to make sure you specify the name of the plugin sub-directory/file.

read more
jqsnipp.com | we just launched jquery snippets website