thehatrack

Chrome Logger API for ColdFusion

About two weeks ago, I spotted a link on either Reddit or Hacker News to a Google Chrome extension called Chrome Logger. I immediately saw the potential, because I frequently want to cfdump something but have to either abort immediately after or worry about my dump disappearing into a thread, screwing up my layout, etc., etc. There were libraries available for PHP, Python, and Ruby at the time (Node was added recently as well), so I figured I may as well jump on board and put one together for CF.

I finished my preliminary work on the component last weekend and used it at work all week, fixing bugs as I came across them. I'm now reasonably confident that it can be put into the wild, so I'm pleased to announce version 0.1 of chromelogger-cf, hosted at http://www.github.com/s992/chromelogger-cf.

In addition to logging simple values, structs, arrays, and queries, I've also added a method to convert objects (primarily ORM entities) into a struct representation, including relationships...

Read more...

Quick Tip: Did your Mura upgrade fail?

mura 0 comments

With my blog still running on Mura 5.5, I figured it was about time that I upgraded to 5.6. I logged into the admin and ran the update, only to find that Hostek caps the execution time on scripts. This is usually a good thing, but in this case my upgrade got cut off midway through. I was no longer able to access the admin and reloading Mura via the URL didn't help. I spoke to Hostek support, who increased the execution limit for the upgrade script, but I was still at a loss as to how I was going to run it! Anyway, if you find yourself in a similar situation, you can hit the upgrade script directly by accessing it at /admin/index.cfm?fuseaction=cSettings.list&action=updateCore (duh). Hopefully this will help some poor, lost soul with a broken Mura upgrade.

Programmatically Creating New Datasources in ColdFusion

coldfusion, mysql 4 comments

I got a new laptop at work. Awesome, right? This thing is blazing fast and a huge upgrade. Unfortunately, I needed to set up my entire local development environment all over again. I managed it with some quick and dirty batch scripts, but I was still left with the tedious task of creating datasources for each of the 40ish MySQL databases that I had imported. Each datasource entry is identical except for the database name, so I figured there must be a better way of doing it than manually creating each entry. Sure enough, there is...

Read more...

Integrating SendGrid With Your ColdFusion Application

sendgrid, coldfusion 3 comments

The majority of my day today was spent evaluating SendGrid and fiddling around with the API. For those of you unfamiliar with SendGrid, it's a hosted e-mail delivery service. At the very (very!) basic level, they provide a mailserver that you can use for your application. Of course, it's much more than that - the reason I was looking into it today is because we need a solid e-mail provider for e-mail newsletters for our clients. Currently, we are using an incredibly outdated version of Lyris List Manager and it's right about time that we replace it. Now, SendGrid doesn't provide any list management, that will have to be done in the application. What I'm about to show you is how to interface with SendGrid to send (potentially) copious amounts of e-mail very, very easily.

Read more...

Hiding Mura Navigation Elements From Unauthenticated Users

mura, coldfusion 2 comments

Today on the Mura Show, frostino asked how he could hide a navigation item from display until a user logged in. Mura is built in such a way that it displays all navigation items regardless of whether a user is logged in or not and then forces the user to log in if they try to navigate to one of those pages. This seems counter-intuitive to me - I prefer to show the user what they have access to and not tease them with stuff they can't get to :). But, I digress. The question piqued my curiosity, so I went digging and came up with an easy solution.

Read more...

©2014 theHATRACK