WordPress tip: Modify any role name to fit your needs

September 15, 2014 at 1:38 pm

Have you ever wanted to change the default role names (Administrator, Editor, Author, Contributor, Subscriber) within WordPress? Here is a super useful snippet to do so.

Simply paste this code into your function.php file. Edit lines 5 and 6 at your convenience.

function wps_change_role_name() {
    global $wp_roles;
    if ( ! isset( $wp_roles ) )
        $wp_roles = new WP_Roles();
    $wp_roles->roles['contributor']['name'] = 'Owner';
    $wp_roles->role_names['contributor'] = 'Owner';
add_action('init', 'wps_change_role_name');

Thanks to Kevin Chard for the tip!!

Win Membership to CrocoBlock WordPress Theme Club

September 7, 2014 at 7:23 pm

I believe you’ve missed giveaways and if so, here is the one you might like. The giveaway is aimed at all WordPress fans reading WpRecipes.com because it gives a chance to win access to beautiful WordPress themes.

I’m looking for 3 winners, and each winner will get a one month membership to CrocoBlock, or it would be better to say a one month membership to the fastest growing WordPress theme club on the net.

About CrocoBlock

CB is a recently launched WP themes club which grows really fast. As of now, there are over 90 themes at CrocoBlock, among them are WordPress themes, WooCommerce themes and JigoShop themes. But the best thing is that new themes are released every week.Now let’s get to the details of the giveaway.

As I’ve already mentioned I’ll choose 3 winners:

  • The 1st winner will get Premium Membership (regular price $95)
  • The 2nd winner will get Developer Membership (regular price $75)
  • The 3rd winner will get Standard Membership (regular price $55)

Detailed information about membership levels is available here.

How to Win

  • Look through CrocoBlock themes and let me know which of them you like best (you can simply comment with the theme name)

Please: make sure you leave your comment before Monday, September 15, 2014.
Good luck everyone!

11 Professional Email Templates from ChocoTemplates – only $12

July 28, 2014 at 2:01 pm

Having a nice, professional-looking email template can certainly increase your chances of member engagement. So jump on this Mighty Deal from ChocoTemplates now and you can get yourself 11 high-quality email templates to work with.

This bundle includes more than 100 color variations and 500+ layered PSD files worth of email templates that are compatible with most of today’s popular email clients. And for a limited time only, thanks to this deal, you can get them all for just a little more than $1 per template.

ChocoTemplates Email Template Bundle Highlights:

  • 11 Professional Email Templates:
    When you email customers and clients you want to look as professional as you can. And that’s exactly what you can do with this bundle of 11 different high-quality email templates from ChocoTemplates.
  • 100+ Color Variations:
    Changing up the colors on your emails is a snap with this template. Just choose the color you’d like from 110 different color variations and you’re good to go.
  • Highly Customizable (PSD option):
    Choose the PSD files version of this deal and you’ll get all the necessary Photoshop files to customize as you see fit. That’s 528 layered PSD files to easily find and change what you need.
  • Compatible with Popular Email Clients:
    These ChocoTemplates email templates have been road tested in all major email clients. So you know your message will get through to your subscribers no matter what they’re using to read your emails.
  • MailChimp Ready:
    Use MailChimp for your email management? Great! These templates are MailChimp ready, making integration ridiculously simple.
  • CampaignMonitor Ready:
    Integrate your emails with CampaignMonitor to easily keep an eye on the overall success. All email templates come CampaignMonitor Ready, so you can get them hooked up in no time flat.

This collection of email templates normally sells for $242, but for a limited time only, you can get all 11 email templates for just $12 – That’s a killer savings of 95% off the regular price, OR get all 11 email templates PLUS the invaluable PSD files for just $18, instead of the regular price of $352.

See all the templates

24 Premium WordPress Tesla Themes (+ optional HTML Themes) – only $25

July 14, 2014 at 5:14 pm

Sometimes we get deals that are so crazy popular, we just have to bring them back. That’s happened with our Tesla Themes bundles in the past. Well, guess what. Not only are we bringing back this unbelievable premium WordPress Theme deal, but we’re making it even bigger and even better than ever before.

If you act now, you can save almost 50% off this bundle of 24 premium WordPress themes from Tesla Themes. Built on the Tesla Framework, these WP themes don’t just look amazing, they’re also insanely customizable and are mobile-friendly, thanks to their responsive design. You also have the option of purchasing most of the themes as stand alone HTML templates, for non-WordPress sites.

Tesla Themes Bundle Highlights:

  • 24 Premium WordPress Themes:
    Doesn’t matter if you’re redoing your own website or putting something together for your clients, this collection of 24 premium WordPress themes is sure to have something for everyone! Your purchase of this Mega Mighty Deal gets you high-quality themes in a wide range of blog topics including photography, travel, business and more.
  • Highly Customizable:
    Built on the robust Tesla Framework, every one of these themes is highly customizable. Using an Advanced Options Panel, you can easily (and quickly!) update the look and feel of your WordPress site. Change up things like colors and fonts, add various features, and even use shortcodes for additional functionality.
  • Mobile-Ready:
    The Tesla Framework is built with a responsive design. That means your users can access your site no problem, on any of today’s popular portable devices such as smartphones, tablets, laptops, and more.
  • Easy to Use:
    You don’t need to be a top-level programmer or even an amateur one, to customize your site! With these Tesla Premium WordPress themes, you can take advantage of the easy drag-and-drop interface to quickly update the look and feel of your site.
  • Custom Widgets:
    Widgets are so much fun on WordPress sites. They make it real easy to add fun, interactive sections to your site. Tesla even created a number of custom widgets for their themes including: recent comments, feature posts, Twitter feeds, Flickr photos, and more.
  • Loads of Shortcodes:
    Entire features can be added to your site with a few simple characters. Known as shortcodes, you just paste in a quick word or phrase in the appropriate section, and suddenly you have a new feature! Tesla Themes offer a ton of shortcodes to let you show off great content such as maps, quotes, horizontal rules, buttons, embedded videos, and more.
  • Optional HTML Templates:
    In addition to the 24 WordPress themes, you can also get 23 of the themes (all, except for the Hudson theme) as stand alone HTML templates. These HTML templates look identical to the WordPress themes, without the WordPress functionality, so you can adapt these to suit your needs. The regular price for the HTML themes is $15 per theme ($345 total), but you can get all 23 HTML themes through this deal for just $10 extra.

Normally, this set of premium WordPress themes sells for $49, but for a limited time only, you can get all 24 Premium Tesla Themes for just $25, OR choose to get all of these WordPress themes PLUS the HTML templates for 23 of the themes for just $35. The HTML themes alone are worth $345 regularly – a total savings of over 90%.

See all the themes

Simplify WordPress With MotoPressContent Editor – only $9

June 23, 2014 at 2:48 pm

How great is WordPress? The popular open-source CMS just has so many options available from different themes, templates, and plugins. The best part of all that is that everyone’s working to improve the core product and make it even easier to use. If you find yourself often frustrated with the default editor that comes with WordPress, it could be time for a change. It could be time for MotoPress.

A simple WordPress Plugin, MotoPress replaces the default editor and makes content editing a snap. Using super easy drag-and-drop methods, MotoPresscouldn’t make life any simpler for you, unless it actually wrote your posts for you! It not only works on any WordPress site, but it’s also accessible on any device too, thanks to its flexible responsive design. As if you needed any more convincing… you can snag this incredible plugin for a mere $9.

MotoPress Content Editor for WordPress Highlights:

  • Fully Compatible With All WordPress Sites:
    MotoPress easily replaces the standard WordPress editor and works with any WordPresstheme out there. So no matter what WP theme you have on your site, you can rest assured that MotoPress will seamlessly fit right in.
  • Easily Customize Your Content:
    With MotoPress’ WYSIWYG editor, mixing up your content has never been simpler. Just drag and drop whatever content elements you want to create a custom look for yourcontent.
  • Works On All Devices:
    Built on a Responsive Design, MotoPress will function on any device you’re using. So whether you’re on your desktop, a laptop, an iPad, or even a smartphone, you’ll still be able to access and fully utilize MotoPress’ vast arsenal of editing tools.
  • Tons of Popular Built-In Features:
    MotoPress doesn’t just make your editing easier with its simple drag-and-drop functionality, but it also includes a ton of popular built-in content elements. Access all sorts of feature elements like text, image, slider, buttons, videos, custom code, space, and loads more.
  • Add Your Own Shortcodes:
    Have your own shortcodes you’d like to work into your content? Not a problem! MotoPresslets you extend the functionality by adding your own shortcodes.
  • Custom Post Types & WPML Support:
    MotoPress supports custom post types. It’s also WPML compatible, for creating fully multilingual WordPress websites.

A personal license for MotoPress normally sells for $29 (for 1 website), but today for a limited time, you can get this powerful and simplifying WordPress plugin for only $9 – That’s more than 65% off the regular price, OR, get the Business license (for 5 websites) for just $29, instead of the regular price of $79, OR even better, choose the Developer license, which allows you to use MotoPresson unlimited websites, for only $49 instead of the regular price of $139.

See the demo video

WPZOOM giveaway: 5 ZOOM Builder plugins to win!!

May 15, 2014 at 4:31 pm

Released last month, ZOOM Builder is an amazing plugin by WPZOOM. It allows you to build a layout by using only drag and drops. Today, I’m glad to announce our new giveaway where 5 winners will get a copy of this amazing plugin.

A word about ZOOM Builder

ZOOM Builder is a WordPress plugin which you install just like any other WordPress plugin. Unlike other WordPress plugins, though, once you’ve got this thing activated it offers you awesome power in building your site’s layout how you want it. The layout builder works through drag and drop. You just drag either one of the ten included modules or any WordPress widget and drop where you want it to go. You can resize or move modules around; it’s really super simple.

ZOOM Builder from WPZOOM on Vimeo.

ZOOM Builder works with any WordPress theme and has been built with security, speed and search in mind. It’s also fully responsive and come with 10 built-in layouts. Just click here if you wanna know more about this amazing plugin.

How to enter the giveaway

Taking part in the giveaway is very easy: Just leave a comment on this post to let us know you’re in. On Thursday 22, I’ll randomly pick 5 lucky winners which will receive the ZOOM Builder plugin from WPZOOM.

Good luck everyone!

How to remove login shake effect when error occurs

April 3, 2014 at 4:53 pm

Don’t like the “shake” effect which occurs each time a login error occurs? Here is a super easy snippet to remove it for good.

Simply paste the following code into your functions.php file:

function wps_login_error() {
        remove_action('login_head', 'wp_shake_js', 12);
add_action('login_head', 'wps_login_error');

Credit: WordPress Support Forum

MightyDeals giveaway: 3 WordPress themes bundle to win

March 27, 2014 at 12:15 pm

Long time with no giveaway here on WpRecipes! Today, my partners from MightyDeals are offering you the chance to win a bundle of 5 amazing WordPress themes. Just read, and join if you want to win!

A word about Mighty Deals

Mighty Deals offers unbelievable deals and discounts for creative professionals.The deals include products and services that are heavily discounted, exclusively for Mighty Deals customers, usually from 50% to 90% off. Each deal stays on the site for a very limited time and is available exclusively for purchase directly through the site.

The prize: DesignerThemes themes bundle

On this giveaway, you can win an amazing bundle of 5 gorgeous, high-quality WordPress themes. Their beauty is more than skin deep, though, as these themes are built on a responsive design, include an intuitive options panel, are highly customizable, SEO friendly and more! Wanna know more about the bundle? Then just have a look there!

How to join the contest?

Taking part in the contest is super easy: Just leave a comment on this post to let us know you’re in. In one week (April 2, 2014) I’ll randomly pick 3 winners which will receive designerthemes bundle directly from MightyDeals.

WordPress tip: Bulk delete comments with a specific url

March 14, 2014 at 5:54 pm

Even if you’re careful when approving new comments, sometimes you might just forget to visit the commenter url and detect a long time after that the linked site is spammy. Here is a very easy way to bulk delete all comments with a specific url, using a simple SQL query.

Just run the following query on your WordPress database to delete comments with nastyspamurl as url. Don’t forget to replace the table prefix wp_ if your database is using another prefix.
And of course, create a backup of your database before running the query!

DELETE from wp_comments WHERE comment_author_url LIKE "%nastyspamurl%" ;

How to set the default image size in WordPress galleries

March 11, 2014 at 6:07 pm

By default, built-in WordPress galleries use the size “full” for the image but in some cases it’s better set a different size. Here is an easy to use code snippet to set the default image size in your galleries.

Simply paste the following snippet into your functions.php file:

add_shortcode('gallery', 'custom_size_gallery');
function custom_size_gallery($attr) {
     $attr['size'] = 'medium';
     return gallery_shortcode($attr);

The desired size can be changed on line 5.

Thanks to emoticode for the cool tip!