Today I've published my latest WordPress plugin. This time I'm bringing voting polls to your WordPress blog or site in the form of Quick Poll WordPress plugin. My goal was to create highly WordPress integrated open source plugin with all features you expect to find in such software. I've also tried to blend voting poll functionality into usual WordPress features, that's why I chose custom post type WordPress feature to implement voting polls. This way you can publish and edit voting polls in the same familiar manner as you control regular posts and pages.
Continue readingCategory Archives: Web Development
Securing your WordPress plugin AJAX calls using nonces
In my last article on this topic I wrote about proper way of implementing AJAX with jQuery in your WordPress plugins. In this article I will show you how to implementing AJAX with jQuery in your WordPress plugins in more secure way by using WordPress nonces. Cryptographic nonce is number passed during communication whose purpose is to prevent someone sniffing authenticated communication to commit replay attack
by replaying captured communication request. Nonces protect you because every request has its own unique nonce, this way both sides can detect replay attack attempts. Now lets take a look at how WordPress implements nonce security. Continue readingProper way of implementing AJAX with jQuery in your WordPress plugins
AJAX (Asynchronous JavaScript and XML) is web programming technique used on client side to fetch data from server side without reloading page. In this article I will write about proper way of implementing AJAX with jQuery in your WordPress plugins. Ajax has been around in WordPress code for a while now so WordPress developers have prepared a few functions and techniques to make our life a bit easier so lets get started.
Continue readingDebug Apache mod_rewrite by enabling logging feature
Mod_rewrite is Apache web server module that enables you to do behind scenes URL rewrite on your Apache powered web site. Using mod_rewrite you can make your site URL's user friendly and hide your site inner workings to increase security. Writing mod_rewrite rules requires some effort to master regular expressions and somewhat hairy mod_rewrite syntax. The whole process is much easier when you have insight to rewrite engine. In this article I'll show you how to debug Apache mod_rewrite by enabling logging feature while creating your rewrite rules.
Continue readingRedirect and send "301 Moved Permanently" when permalink structure or slug has been changed WordPress plugin
Believe it or not but changing WordPress permalink structure can actually temporarily remove your site from Google index. Also changing single page slug can do the same for that page. By default WordPress doesn't forgive these kind of changes and following old permalinks would usually result in "404 Not Found". In this article I'm bringing you WordPress plugin that enables you to redirect old permalinks to new ones after changing permalink structure or slug. This WordPress plugin will also send "301 Moved Permanently" headers to search engines and that would instruct Google and others to change their search index.
Continue reading