Resource – URL Rewriting for the Fearful

Link:

http://24ways.org/2013/url-rewriting-for-the-fearful/

Description:

Fantastic article by Drew McLellan on using url rewriting in your .htaccess files. Covers basics and real world examples. Great as a resource for order of operations, common flags, pitfalls, and sample code. Heavy emphasis on rewriting used by common web frameworks, such as rewriting every request to a master URL for MVC delegation.

Notes:

  • URL rewrites will send new matching URLs through the rest of your rules. Use the “L” flag or plan accordingly by having “real” files in an excluded directory.
  • Another resource linked from the article – mod_rewrite Beginners guide.

Resource – Intro to Grunt by Chris Coyier on 24 Ways

Grunt.js

Link:

http://24ways.org/2013/grunt-is-not-weird-and-hard/

Description:

Fantastic resource on getting started with Grunt.js. Practical implementations of script concats, minimizing, and automation. Recommend as a simple resource and starting template for many common web site tasks.

Notes:

JavaScript Bookmarklet: Outline/Border all Elements of Site for Quick Development & Debugging

Need to outline all HTML elements on an open web page? I’m sure there has been a time when you’ve used something like this to do so:

 * { border:1px solid red; } 

Which gives you a quick visual look at all elements on the page and how they align. It’s simple and by all means works just fine.

To make things even more convenient, here’s a quick and handy little JavaScript bookmarklet for you web developers to save. Full credit and thanks go to “beaver82” in the following /r/webdev/ thread. I’ve edited one of his/her original scripts to include a border instead of outline,  in case you do want to affect the box size.

Demo of the Outline Elements JavaScript Snippet
Demo of the Outline Elements JavaScript Snippet

Snippets:

The border/outline scripts are distinguished by the file names listed above.

Usage

  • Drag or save the JavaScript snippet desired (either js_border_elems.jsjs_outline_elems.js, or both) to your browsers bookmarks bar.
  • Name it something useful, such as “Outline * Elements
  • Click on the snippet to outline/border elements on the current page. Click again to remove the outlines/borders.

Enjoy! If you have any similar useful snippets, please do share them in the comments section.

Dropbox Adds Two-Step Verification, 1Password Users Asked to Wait.

The popular backup and file syncing service, Dropbox, has just announced that two-factor authentication is now available for users.

This is great news and it’s nice to see more and more websites start to use two-factor authentication.

Dropbox Two-Step Verification
Enabling Two-Step Authentication for Dropbox.

If you don’t use 1Password app, you should go enable it now.

1Password Users, Hold on a Sec.

For those of us who use 1Password, you might be surprised to hear that the 1Password team recommends that most users should wait a bit while a few things are tested and looked into.

This is mostly due to it being a very new feature with little documentation, and the team wants to ensure should anything go wrong or get stolen, your data is always accessible.

The “Agile Bits” team (creators of 1Password app) always does an amazing job at explaining their decisions and app in depth, so I highly recommend you read their post before enabling two-factor auth in Dropbox.

The 1Password team specifically updated their post with the following optimistic snippet:

In conjunction with Dropbox moving this out of beta and the experience of lots of 1Password users switching over to two-step authentication, I’ve become much more optimistic about when we will feel more comfortable recommending this to 1Password users. I changed my guess of “months” to “weeks”

So there you have it. If you don’t use a password manager (bad computer user, bad!) then you should enable this right away. If you do use the 1Password app or a similar password manager, you should read the blog post first and make your own decision.

Article Resources

Mac OS X Gestures Freeze or Stop Working? Here’s a Quick Fix.

Update: Alfred extension released for those of you who would prefer not to tinker with Terminal. See bottom of this post.

Mac OS X gestures freeze or stop working? Perhaps your hot corners or Launchpad also stopped working? I’ve also experienced this and have a quick one-line fix.

Here’s what usually happens:

  • You’ve been on your Mac for a while and suddenly gestures aren’t working for you.
  • Clicking on “Mission Control” and “Launchpad” don’t work.
  • Hot corners also may not be working during this time.

If you’ve experienced any of the issues with gestures as described above, the good news is there is a quick fix.

What’s the fix?

The fix is to restart or “kill” the dock. This isn’t as scary as it sounds. This won’t close any of your currently running apps, but the dock will disappear for a bit, restart, and then re-appear.

To do this, fire up Terminal and type the following:

killall Dock

That’s it. Your dock will restart and your gestures and hot corners should work again.

What Causes This?

I’m not sure why gestures randomly freeze or stop working. I don’t think it’s a 3rd party software conflict as I’ve had this happen while only running Safari.

I’ve seen a few forum threads from a google search with many users having the same issue, so I assume it will be fixed by Apple as they polish gestures up a bit. If you have any insight or suggestions please do leave them in the comments section.

I’m also considering making an Alfred extension for those of us who don’t always have the Terminal ready and waiting, or, for those who don’t feel comfortable with the Terminal/CLI.

Update: Alfred extension “Mac OS X Gestures Freeze Fix” has been developed and released for all of you Alfred users.

More plugins and Alfred scripts I’ve created can be found at  software.creatingdrew.com.

My Software – Subdomain Launched and Being Updated

I’ve finally found some free time to get a new sub domain setup for all of the software I’ve created.

You can check out the new site at software.creatingdrew.com.

I’ll be merging my existing software, plugins, & extensions into the site over time. Many of the plugins and extensions from Dev-Tips.com (now closed) will be merged into the new site as well.

I’ve just added an Alfred App extension to allow you to toggle hidden files super quickly on your system. I’ve also put up a much requested update about the “Are You Sure?” WordPress plugin that some of you used in the past.

If you have some time to swing by the new site or give it a share, I’d appreciate it.

Stay well and keep smiling. 🙂

Adding Custom Header Images to WordPress.org Plugins

While reading WPCandy’s “Recap: Matt Mullenweg’s 2012 State of the Word“, I came across a note about custom plugin header images.

This may not be news to some plugin devs, but you are now able to use your own custom header image for your WordPress plugins hosted on WordPress.org.

If you don’t spend much time browsing the actual plugins directory, you may not have noticed this. A great example of a custom plugin image in use is the infamous “Hello Dolly” plugin hosted on WordPress.org.

Hello Dolly WordPress Plugin Showing Custom Header
Hello Dolly page showing custom header image in use. Click for larger view.

The image needs to be a 772×250 pixel jpeg or png. This goes into your plugin’s SVN directory with the path assets/banner-772x250.(jpg|png).  Resources to get started with custom header images for your WordPress plugin:

Be warned, Matt has stated that this will most likely change in the future. If anyone has any more up to date details or resources, please let me know in the comments.