Reading Today

Back to the Future in 2016

“A funny thing happened on the way to 2016. We asked some of our smartest friends in the web design and development communities what new skills they planned to master, or what new focuses they intended to bring to their work, in the new year.”

read full text »

Force Editor Reparsing with Codemirror

I’m working on a personal project where there’s a comparison of original text to text being typed. When the original text is changed I wanted to be able to force a reparsing of the text being typed by the user. instance is the what is returned when you instantiate your Codemirror editor. The code is … Continued

How to Force Close One (unruly) Tab in Chrome

How to Force Close One (unruly) Tab in Chrome

Wow, the fan is blowing and the page is continually loading and working on some js (I assume) I screwed up.   The tab won’t close by x or cmd+w. In chrome; Window->Task Manager, select your tab and End Process. And voila. How have I missed this?

Do not ever use the guid element for creating links – ever – ever

I was recently (I always seem to start posts with that phrase) learning how to update a clients posts post_title, slug (aka post_name in the db) and guid when a post title was changed programatically. I was using get_sample_permalink() in combination with wp_update_post() to generate a permalink and update the post guid along with the … Continued

Force Post Author Comments to Moderation in WordPress

By default in WordPress when an author of a post comments on their own posting the comment is automatically approved. This makes sense when authors are associated with the site, have access to admin, etc. There are cases where content from the general public is used to create posts and while the user is logged … Continued

Always Unset Values Passed by Reference in a Loop

I’d always read to unset the variables passed by reference in PHP’s foreach loop. Here’s an example: In the above code I was looping through a set of parent posts and using a custom method to get what I was calling the ‘current version’ which was really just the most recent child post. Then I … Continued

Allow html in Contact Form 7 error messages

Contact Form 7 has a filter where one can alter the messages being sent back to the browser called wpcf7_validation_error. A simple htmlspecialchars_decode altering the $message variable before returning will do the trick. This function will run on any error for any form you have in your site (any CF7 form that is). If you … Continued

Trusting the Development Process (spoiler: it’s not about trusting)

The Setup I’ve recently started using quill.js in a personal project I made up; specifically so I could build something with quill.js. The app is geared towards learning pieces of text by rote learning. The user will pick a piece of text or enter their own in one text editor and then retype it in … Continued