Ajax call returns -1 in WordPress Plugin?

I came across this problem while developing a plugin for a client. I made the Ajax call properly using the following code $( "#hform-leads" ).click( function() { var username = $("#username").val(); var data = { action: ‘register_lead’, username: username }; … Continue reading

Posted in Uncategorized | Leave a comment

WordPress Blog Hacked with Footer Spam Links (rankexplorer poker software)

One of my wordpress blogs got hacked last week with spam links. First i noticed a single link to a site rankexplorer.com with anchor text poker software – inserted at the bottom of my blog pages. The links increased to … Continue reading

Posted in wordpress | Leave a comment

How to Enable Custom Taxonomy Terms for Non-Admin users in WordPress

When you add custom taxonomy for your posts (including custom post types) – by default the taxonomy terms can be added and assigned from the post edit screen when you login as Admin (or as an editor). But, if you … Continue reading

Posted in wordpress | Leave a comment

Word Press Remove Blank Line From RSS Feed Error Fix

Are you pulling your hair out trying to solve this error? If you are not a geek then most probably you are doing just that! This error is generated when the feed output generated by WordPress contains a blank space … Continue reading

Posted in wordpress | Leave a comment

Get Users List by Role in WordPress

To get the list of all users in your wordpress blog use the following code: <?php $users = get_users(); ?> This function returns an Array of user objects as follows: Array ( [0] => stdClass Object ( [ID] => 1 … Continue reading

Posted in wordpress | Leave a comment

What Every WordPress Plugin Developer Should Know

This is one excellent tutorial from smashingmagazine.com In a nutshell following are the main points from this article 1. Turn on debugging feature before you start developing a plugin 2. Provide unique prefixes to your plugin function names 3. Create … Continue reading

Posted in wordpress | Leave a comment

Generating a list of Random Numbers in PHP

I created the following code while working on a wordpress plugin. As usual, first i searched in Google for a short cut way to do this! Turned out, lots of people were having trouble generating a list of random numbers … Continue reading

Posted in wordpress | Comments Off

Adding Pagination to List of Records in a WordPress Plugin

This guide can be used for any wordpress plugin that need to display records in a list format. These records can be either existing records from core wordpress database or custom records created by the plugin. Click here to view … Continue reading

Posted in wordpress | Comments Off