My Long Putter Isn't Going Anywhere

So, it's official. Anchored putting strokes are banned starting in 2016.

Prior to this season, I switched to a long putter. Truth be told, it's the first putter I ever purchased myself. Until now I had been using the putter my Dad made for me (part of my first set of clubs, now over 20 years old, which was replaced last year). My reasons for going to the long putter are simple. I am more comfortable standing upright.

When I was considering the purchase, the potential ban on anchoring weighed in my decision. I am 99.9% sure I will never be playing in a USGA/PGA sponsored event. Quite frankly, my short term goals are to shoot in the 80's consistently. Also, I am pretty sure I am in the minority of most amateur golfers in that I try and follow the rules to the best of my knowledge. No foot wedges or questionable ball drops here. So when trying out the long putter, I put a lot of time into seeing how it felt without jamming the butt end into my sternum. The answer was, "just fine". Right now my left hand barely touches my shirt when I put, if at all.

The long putter has already shown benefits in my game, no doubt. I feel more comfortable in my stance, and I see the stroke better. Looking into more detail of the rules, I will have the spend some time working on consciously keeping the butt end far enough away to not bring any questions that I am following the rules. And I intend to do that. But I have 2 1/2 years to figure that out.

In the meantime, my short term plan is to not worry about if I unintentionally anchor (I think I might with my left arm to my side at times, not sure), but to get a consistent stroke in place. Once I have that done, then I'll worry about focusing on tweaking it to conform in whatever ways are needed.

And on the bright side, maybe the ban will scare off so many people from buying long putters that stores will drop prices on the high end models to be somewhere I could afford to get one someday!

On Frameworks, and their Evangelists

Let me start this entry with a clear statement.

I have no problem with frameworks, as a rule. If asked to use one for a project, I would do so without complaint. But if given a choice, I will use my own time-tested processes instead.

Okay, now onto the rest of the entry.

Last night I got into a twitter discussion with someone who is clearly an evangelist of CFML frameworks. His position is that anyone not using a framework is, in his exact words, "crazy". I greatly differ with that opinion, and it broke down pretty quickly when he was confronted with someone with a dissenting opinion. I offered him to contact me outside of Twitter to continue, but he has not responded. So consider this my response.

I have spent the majority of my 15 years using CFML not using frameworks. The last 8 years I have been part of a team that has put together a very solid set of coding standards for our development team, with a few rules (backend work in components, putting stored variables in the proper location for their intent, etc.) and with that we have turned out multiple applications for the Department of Education that are stable, fast, promote code reuse, and scalable. The biggest proof in our processes are that when new developers join our team, there is little in the way of a learning curve to do things "our way".

In my free time, I have tried out three different frameworks: FW/1, Fusebox, and Mach-II. All were fine. None of them wowed me in any way that made me think I should propose getting away from our processes and use a framework instead. A framework is an organization tool, nothing more and nothing less. It defines rules for how one must code. It sets up boundaries. It may even limit creative freedom (that's just a gut feeling on my part). They are useful, especially for a disorganized team or a junior level developer making their way into the CFML world.

It is not, however, the end-all, be all. I have seen both sides of this argument, and in the end I say what I have always said: It doesn't matter what tools you use to code, only one thing matters - the people developing the code. A great developer not only knows what can be done, they also must know when the right time to use it is. There are great developers that use frameworks religiously. There are also great developers that do not.

Now for the bigger issue at hand. Frameworks biggest problem right now is their supporters. These people range from supporters to evangelists to outright zealots. And the problem with them is that most of them get belligerent when you don't fall into complete agreement with them. Their weapon of choice is to attack or put down people once they realize the person they are talking to doesn't fall in line with them. And that's sad. It also builds a level of resentment that is unnecessary.

So here's a tip to them: if you want to convince people to come to your side of thinking, use logic instead of putdowns. And realize that what works well for you is not going to work well for everyone, and that's okay. In the end, there will always be a human element to software design and that means that there is no one right way to do things. That's a GOOD thing, too.

Quick Hits - A Possibly Handy Guide - CFSPREADSHEET fill colors

Lately I have been using CFSPREADSHEET on work projects. I love the tag and the associated functions. But one thing has been missing from all the associated documentation I can find.

What exactly are the colors you can use for text and fill?

CFSPREADSHEET uses the colors from the org.apache.poi.hssf.util.HSSFColor class, and Adobe and others are nice enough to provide a list of the names. But when I want to pick a color, I like to, you know, SEE the colors!

So, as a help to myself (and maybe some others), I whipped together a spreadsheet with each of the colors available for use. If you find it useful, great!

The download is available here.

What I Learned Today - Getting around AdBlock Plus

I was making small edits to my blog, adding 2 banners to my site for my hosting company and for CFBloggers. They were basic IMG tags, nothing special. But the one for Hostek was not showing up in Firefox when I was testing the changes out. For the life of me I had no idea what was going on, Firebug was showing it to be hidden, and some weirdly named class being attached to it.

After a bit, I ran across a post on HTML Forums that showed me the culprit - AdBlock Plus.

Seems that AdBlock did not like the way the banner image was named (ht_460x68.gif). Specifically the "_460x68" part was being caught (I saw this in the filtering information from teh AdBlock Plus toolbar button). So a quick change of the banner filename, and problem solved!

Verity, OS X, and VirtualBox

This is a follow up entry to one I wrote about using Verity when your CF runs on OS X.

Recently, I changed my virtualization engine from VMware Fusion to VirtualBox. The lone downside to this I have had is that, unlike VMWare, VirtualBox does not allow you to access files on the guest OS (Win7 for me) from the host (OS X). This made my setup for using Verity unusable.

But, as times of need often tend to do, it birthed a new way of doing this. Probably a better one all told. I now host all of the collections and the files they index locally in OS X, and the Verity K2 server on Win7 reads and manipulated them from there. This allows Time Machine to back up these files, which is a plus.

Here are the changes I had to make to make this happen.

  1. Delete the soft link for /opt/coldfusion in OS X, and create a physical directory in its' place.
  2. Copy the collections and documents from Win7 into /opt/coldfusion
  3. In VirtualBox, create a Full Access, Auto-Mounted Shared Folder to /opt/coldfusion. Restart the guest OS for it to take effect.
  4. In Win7, delete the physical folder C:\opt\coldfusion, and replace it with a soft link to \\vboxsvr\coldfusion\. I used the open source Directory Linker tool to do it.
  5. In CF Admin on OS X, update the IP address of the Verity K2 server to the new guest IP (if neccesary).
  6. Purge the existing collections, and re-index.

That's it!

Quick hits - UU2 is the best friend you never knew you had

This one is for anyone administering their own CF server.

If you don't know about Unofficial Updater 2, go there now and meet your new best friend. Maintained by David Epler, this project makes keeping your CF server updated as simple as is humanly possible.

I'd pay for this service if I had to, I think it's that good.

jQuery Quickie: issue with trim() in IE8

Ran across an annoying little bug in IE8. It seems that, for all other browsers and IE9+, this will work fine:

view plain print about
1var thisE = $(this).text().trim();

But if you want it to work in IE8-, you need to do this:

view plain print about
1var thisE = $.trim($(this).text());

Just another reason I love loathe IE.

jQuery Tip: changing to on() from bind() and live()

This might not be news to some, but if you are using older versions of jQuery, take note of a fairly significant change.

Ran across this today reading the jQuery API docs. The bind() and live() functions are deprecated as of v1.7, and have been removed as of v1.9. They are both being replaced with on().

http://api.jquery.com/on/

I tested changing to on() in some of my own projects, and found no difference in expected results when simply switching from bind() to on(). Just replace "bind" with "on" and you are good to go.

However, if you use live(), you will need to modify your code a little. The main reason I used live() was to have an event handler attached to an element now, or in the future if it's not currently part of the DOM. What you need to do now is attach the on() function to a containing element that will be present in the DOM from the beginning, and use a delegated event to catch the action of the element that will be in the DOM later. It's very straightforward.

Here's an example of that. I have a container DIV with an ID of "myContainer" that is always present in the HTML from the outset. Inside that DIV, HTML will be added later (like an AJAX request to populate it with some HTML based on a button click). Inside that new HTML will be a link that I want to trap and manage in some way. That link will have an id of "futureLink" for this example.

Before, you did this:

view plain print about
1$('#futureLink').live('click',function(e){
2    e.preventDefault();
3    alert("a link was clicked that wasn't here before");
4});

Here's what you do now:

view plain print about
1$('#myContainer').on('click','#futureLink',function(e){
2    e.preventDefault();
3    alert("a link was clicked that wasn't here before");
4});

So, a simple solution to future-proof your code as you upgrade versions of jQuery.

Excel 2013 Doesn't Play nice with CFSPREADSHEET

Ran into an issue with the latest version of Microsoft Excel today. By default, it enables what is called Protected View on all files originating from the Internet. This does a variety of things, including neutering formatting and disabling formulas.

I have an app that generates an XLSX file via CFSPREADSHEET, complete with formatting via spreadsheetFormatColumns() and formulas assigned to cells via spreadsheetSetCellForumla(). It works great in all versions of Excel I tried it in (2007, 2010, Mac 2011, even 2003 via compatibility updates).

I was able to get my hands on Office 2013 for $10 via the Microsoft HUP program at work. I'm glad I did that, because when I tested this same spreadsheet in Excel 2013, it wouldn't open. It claimed the file was corrupt. Knowing that to not be the case, I did some digging and found a few forum posts of people complaining about Excel 2013's Protected View doing the same thing.

I went into the settings and disabled Protected View (located in Options > Trust Center > Trust Center Settings... > Protected View), and tried to open the file again. It worked - mostly. The file opened, but the cell formulas were disabled. I needed to click the Enable Editing button at the top of Excel to get the formulas to calculate. Not very user friendly at all, Microsoft.

For now this is not much of a worry, as Excel 2013 has a tiny user base compared to other versions. And zero user base where people would be viewing my app (limited audience, controlled environment). But at some point this will change, and I hope either Microsoft or Adobe addresses this. My initial instinct is that this is a Microsoft issue.

I did some testing and found that generating an older XLS object at least opened with Protected View enabled, but the cell formatting and formulas were still shot. Enable Editing only fixed the formulas, it didn't fix the cell formatting.

Anyone else run into this yet? If you haven't already, you should consider testing your CFSPREADSHEET-generated objects in Excel 2013 soon!

CF Mappings question

My Unix server is used by multiple groups. The directory names used here are fakes, but representative of the issue at hand.

IBM Webshpere is the web server, with a document root set as /webhome/ CF9 is installed in /cfhome/ In the CF admin settings, CFIDE is mapped to /cfhome/wwwroot/CFIDE/

Someone from another group made a physical directory /webhome/CFIDE/ and copied all the files from /cfhome/wwwroot/CFIDE/ into it. So there are now two physical copies of CFIDE on that server.

A CFM script is placed in /webhome/CFIDE/, call it test.cfm. It does NOT exist in /cfhome/wwwroot/CFIDE/.

When someone uses the URL http://servername/CFIDE/test.cfm, the page runs properly.

By all rights that I am aware of, this should not be happening since CFIDE is mapped to the directory that does not contain the file.

I looked in the httpd.conf file and found zero references to CFIDE in there. I did find these lines containing "/webhome":

view plain print about
1DocumentRoot "/webhome"
2[...]
3# This should be changed to whatever you set DocumentRoot to.
4<Directory "/webhome">
5[...]
6<VirtualHost *>
7ServerName myserver.com
8DocumentRoot /webhome
9</VirtualHost>

So, is the Websphere mapping overriding the CF mapping? And if so, would it be better to just have a soft link from /webhome/CFIDE/ to /cfhome/wwwroot/CFIDE/?

More Entries