Data, Maps, Usability, and Performance

API canvas d3 data geo GeoJSON html5 image JavaScript json maps mysql PHP WordPress

Results for tag: WordPress

Sort WordPress Posts by Modified Date using a URL Param

List Posts by Recently Updated in WordPress

After updating a few older articles on this blog I have realized that it would be useful to provide a display where all my posts are sorted by last modified date instead of created date. I imagine it would just be a link that someone can click and it would change the WP query so that recently updated posts are displayed in descending order. Everything else stays the same. You can see it in action on my homepage and today I will cover how you can do that with two simple WordPress functions.
Read more

Managing and Displaying New Fields for WordPress Users

how to add new attributes to wordpress users

WordPress provides a lot of different hooks that allow you to expand on user management capabilities. You can easily add a new field or attribute for any user and make it editable in the user profile. You can restrict the edit mode to only Administrators and you can visualize any of these new user data points in the main Admin Users table.

So, today, I will write a quick WP Plugin that adds a new user field called credits to all users, which can be updated by Admins in the user profile. The WordPress plugin will also display that field in the Users table along with a new read only field that captures users last login date and time.
Read more

WordPress Plugin with Background Process, Queue, and Debugging

background processing sample WP plugin for async tasks

WordPress Plugins are often used to run a large process in the background like importing, exporting, bringing data from other APIs, pushing data out, and other tasks that should run asynchronously. How do you do that? TechCrunch came out with wp-async-task and WP Background Processing extended that by adding the ability to queue tasks. The author already included a good sample plugin and article but I wanted to see if I can write a more basic example. So, today, I will create a WordPress plugin that uses WP Background Process to queue and run PHP tasks in the background.
Read more

Repeatable Field Creation and Inline Edit with Fromidable Forms

Formidable Forms Repeatable Field PHP

Last year I wrote an article on Gravity Forms and now I want to follow up with something on Formidable Forms. Instead of doing a comparison between these two WordPress plugins, I will write about two problems that I have encountered with FormidableForms and explain how I have resolved them. The first one is based on the backend, PHP code that will create repeatable fields inside a form and the second one goes into the front end, JavaScript code that helps hooking into “in-place” edit.
Read more

Minimalist WordPress Theme

Professional and Minimalist WP Theme

I’m back and happy to announce a new WordPress theme that I have created called Minimalist which you can see on this blog. Why? Because almost all WordPress themes focus on nice design and flexibility while killing performance. It looks great on the cover but then you dig in and see a lot of garbage in the source code, ridiculous amounts of database calls, a large amount of files, and plugins needed for simple stuff. Most of it is not needed.

Minimalist is simple, fast, responsive, and SEO optimized WordPress theme that can be used out of the box or as a great starting point for WP theme development. I only tweaked a few things and applied it on this blog.

Read more

Editing Gravity Forms Entries on The Front-End

edit gravity forms on frontend

If you are using WordPress and the Gravity Forms plugin, you might want to allow users to edit their posts or entries on the front-end. This is not supported by the plugin but there are other plugins or addons like Gravity Forms Edit Entries, Gravity Forms Sticky List, Gravity Forms: Post Updates, and GravityView that provide such functionality. But, they also come with other features that you might not want or need and installing more and more plugins can certainly impact performance. Moreover, a few of the plugins that I have tried would create and delete entries in GravityFroms causing missing Entry IDs which isn’t ideal and it is additional work on the system. Today, I will show you how to edit Gravity Forms entries on a page by simply using GF actions, hooks, and the API.
Read more

20 Free Clean and Minimalist Portfolio WordPress Themes for Seamless Web Development

If you are an artist, photographer or other creative personality, running a portfolio site is essential. Otherwise, what’s the purpose of doing your job if you don’t show your achievements to the world? If you share this point of view, then our blog post today should prove useful to you. Ordering a custom-made design can cost you a fortune. If you are on a limited budget or simply not ready to spend much on a custom-made design, then a freemium website template is just what you need to achieve success.

Today, we have handpicked 20 beautifully designed free portfolio WordPress themes that you can safely download and use for different purposes. Why did we decide to share a compilation of WP themes, you might ask? Well, the answer is simple. According to CMS Usage Statistics by BuiltWith, the WordPress market share has reached 49.47%, and this percentage is only expected to grow with time. The world’s most popular companies have chosen WP from among thousands of other Content Management Systems with which to build their sites. For instance, TechCrunch, The New York Times, Coca-Cola France, Fortune, The New Yorker, and many other well-known names have trusted their online presentation to WordPress. So, if you want your business to gain international recognition, then choosing WP for building an online portfolio would be the right solution.
Read more

WordPress Upload Files with Ajax

WP upload file with ajax

How do you upload files to WordPress with Ajax? Maybe you want fileupload functionality on the front end or enable file uploads in your WordPress plugin. There are a lot of good tutorials on this subject but I couldn’t find any simple example that works with native WP files.

This tutorial on multiple file uploads on the front-end does work but it requires using a server side file for the back end and custom functions in functions.php that use media_handle_upload without Ajax. Tutorials on WordPress file uploads with ajax leverage special jQuery plugins, queuing wordpress scripts, and server side functions to process the Ajax request. This might be needed if you need a lot of control but if you just need to easily upload and delete files, I will show you how to do it in a few lines of simple vanilla JavaScript.
Read more

WordPress on VPS with Nginx and PHP APC

wordpress on nginx

It was time to pay the yearly fee for shared hosting and I decided to check out some VPS options. Performance was not really a problem as WordPress caching plugins do a good job but I wanted more control of the stack and VPS pricing is not that far off from shared hosting. DigitalOcean plans start at 5 dollars and you get 1 Core with 512MB Memory, 20GB SSD Disk, and 1TB of Transfer. You can setup a droplet in 1 minute and you can pay month to month. No wonder they are doing so well, it makes sense to just try them out. They also have great documentation, API, and an easy to use control panel. Here are some details on how I moved my WordPress blog from shared hosting to VPS and made it really fast with Nginx, PHP APC, and Super Cache.
Read more

WordPress Plugin with Ajax and MySQL

WordPress Ajax Plugin

I wanted to follow up from my last post on building a WordPress Plugin Admin Page and write about using Ajax calls with WordPress plugins. It is very common nowadays to use XMLHttpRequest to move data from the front-end to the back-end and WordPress supports this very well. Consider a contact form on your blog, when someone hits submit you could initiate an Ajax request to your plugin and process the data. Today, I will show how to use Ajax with a WordPress plugin and I will build a complete Quick Contact WordPress plugin that stores a form submission to a new database table which is displayed for quick viewing on a new admin page.
Read more