How to remove items from +New admin menu?

This tutorial is actually taken from an answer I gave on StackOverflow to a question by sailingthoms Sailingthoms’s question I would like to limit the +New admin menu to only show the single sub menu Event (“Veranstaltung”). Basically the users are allowed to create other items as well but not from that +New menu. My…

How to handle error messages in PHP

Error messages are nightmares to a programmer. Default error messages are annoying and looking ugly. And kind of security threat as well. You probably wish to show a custom message when an error occurred. And tried and failed? I had written this small code snippet for one of my projects and now wondering if this…

Generate activation or deactivation link of WordPress plugin

You often need an action link to activate or deactivate a plugin. How do you do that? I have written a simple function that can help you achieve this.

How to use? This function requires 2 parameters; first one is the plugin file name, and second one is action type. Plugin file name is…

Edit Next Post – my 16th plugin published in WP repository

As I’m a man of Open Source, I always try to give back to the community. I already had 15 plugins published in WordPress repository. And today, the 16th one just added in the list. Of course free and Open Source. Edit Next Post, the plugin you’ll always need Imagine when you have a lot…

Add a ‘Scroll to Top’ button to your WordPress site

A ‘Scroll to Top’ button can enhance usability of your website. There are several plugins available out there that can help you achieve this. You just need to install the plugin and activate it. Few days back, I’ve written a plugin that adds this feature to a WP site. Unlike other similar plugins, this one…

A simple two-way function to encrypt or decrypt a string

This function will provide you a two-way system to encrypt a string or decrypt an encrypted string.

So, how to encrypt a string? Just call this function and pass your string. Additionally set your second parameter to ‘e’ (optional). To encrypt Hello World!, write-

It’ll generate a encrypted string RTlOMytOZStXdjdHbDZtamNDWFpGdz09 And, how to…

Change WordPress password when ‘reset password’ is not working

Imagine a situation when you forgot the password of your admin account of your WordPress site, and ‘reset password’ is not functioning. Or even, you cannot remember the email you used for it. You cannot access the wp-admin area. Now what? Well, there’s a solution. You can change the password from phpMyAdmin without knowing previous…

How to stop WordPress from generating multiple image sizes

When you upload an image using the media uploader of your WordPress site, it creates multiple sizes of that image. By default, WordPress creates 4 additional sizes, but your theme and/or plugin(s) may create more sizes of that image. And it’s really a headache when you are considering your storage. So, how to stop it?…