How to Create a WordPress Plugin

Plugins are ways to extend and add to the functionality that already exists in WordPress. We don’t have to be a dedicated plugin developer to write WordPress plugin. There are situation where we need to alter some existing functions, or add some features to existing site. You may learn from various resources that, to add this, you need to drop code snippet to function.php. The fact is, making changes to function.php isn’t always the best solution.

Continue Reading →

Dynamically Populate a Select field from Custom List

When we start using Custom Post Type & Custom Field to enrich our WordPress website, to meet various real world situation, building relationship between different datasets becomes a common practice. A simple example, is project & client relationship. If we manage this in database, we always link client to project using client ID, because client may repeat in multiple projects. If we use Custom Post Type to manage project and client in WordPress, the challenge is: how do we dynamically populate a latest client list into a client choices for a project?

Continue Reading →

Take Control of Post Revisions

WordPress revisions system saves a record of each saved draft or published update. This feature is important to site owners, because it provides some sort of “backup” for the content in case you accidentally edit posts the wrong way. By default, WordPress saves every copy of revision when you click Save button. All the revision copies take up room in database, will eventually slow down the query time, especially on sites with many blogs.

Continue Reading →

Restore Custom Post Type from History that doesn’t have Revisions Enabled

I know the title sounds a little wired, here is the background story. WordPress has Revisions system stores a record of each saved draft or published update. It is enabled for Post & Page. But in Custom Post Type, Revisions support is up to the theme developer to enable it. As long as you use themes, you should have noticed that, in some themes, the revisions is disabled on Custom Post Type by default. When Custom Post Type is used for short content such as Testimonial, it isn’t much of trouble to restore a revision. But not for a CPT post with a lot of content.

Continue Reading →

Quick Fix for Working with Absolute Path on Temporary URL

Can’t think of a better title, here is the scenario: After creating a new account at hosting service provider, we are normally assigned a temporary URL before link this hosting account to domain of final production site, for example: http://hostingserver.com/~username. Sometimes, we have to work on the temporary URL through development stage before site goes live for various reasons. The temporary URL creates temporary trouble to some not well-written code in case “absolute path” is used in either themes, plugins, or existing site. The trouble can be either broken links, or missing images.

Continue Reading →

Download failed. Failed to write request to temporary file.

When trying to update stock Twenty Fourteen theme today, I ran into a theme update failing problem. The error message is “Download failed. Failed to write request to temporary file.”. The first reaction was file / folder permission setting. But it wasn’t the case this time.

Continue Reading →

How to Make TubePress Responsive

TubePress is a well-designed plugin that brings YouTube or Vimeo video gallery into WordPress website. With easy CSS hack, we can easily fit TubePress video gallry to different theme. But out of the box, TubePress doesn’t offer responsive option.

Continue Reading →

Troubleshooting: BackWPup Next Cron Job at Dec 31, 1969

As usual, on the new website, I created few backup jobs in BackWPup (Free) – my favorite WordPress backup plugin, setup the scheduled start time with WordPress cron. Because I setup one daily backup also send a copy to Box.Com via email, which will trigger an automatic notification email from Box.Com, I get to know if the scheduled backup is executed on time. But something strange happened after the following two days. The scheduled backup didn’t start as expected.

Continue Reading →

Troubleshooting: Archive Link Not Working

On one of my WordPress website, the archive link is not working. The site has over 2 dozen plugins installed, and just been handed over to me a week ago. I have no clue when and what was done to the site, neither did my client. Instead of the usual routine of disabling all the plugins, I turned to Google Search. There are few possible solutions, I quickly located mine.

Continue Reading →