Testing Tools

A couple of useful testing tools I thought I’d share:

The latter seems a little buggy, but still easier to use than removing and installing different Flash versions yourself.

Brochure Ape 3.0 (alpha)

Over the Last several days, have been pounding away on a CMS that really takes it’s inspiration from some of the work that Chris did for U-Penn. (It is also partially inspired by cake, and by joomla.) The idea is for the app to be as easy to install and use as is humanly possible. At the same time I expect that some more impressive things will need to be done by more advanced users, so I have sub-divided usage patterns out into 5 levels.

Installation: I’m hoping to get this as simple as possible. I took the time to write up a custom script “installer_helper.php” that drags the user kicking and screaming through the installation process. Hopefully this is enough, though a few steps still seem to hard. (Rather horrifically, the first one is the worst.)

Publisher: Hopefully this will be so easy that an ape could do it. You can either be logged in as an admin, or visiting the page. If you are logged in and visit a page that doesn’t exsist, you get the option to create the page, by selecting from a list of templates. The new page is automatically added to the master navigation. Each of the templates has areas of text, Images, and other sundry that can be edited by clicking on the little “edit” button next to them. Publishers will never need to touch the web server, or HTML.

Designer: New templates useing the smarty mark-up rules. Their are a few additional calls that can be made to put in editable fields, but for the most part it just straight HTML. The new template is simply deposited in the “view” directory, and then becomes an avalible option for the Publishers. Javascript, Images and CSS can all be put in their respective directories in “webroot”

Developer: If you need to add some actual functionality to the site, Brochure Ape can act as a rough and ready framework as well. Custom PHP code can be written, and put in files in the “controler” directory. At any point if a page is created that matches the name of a controller, it will run both the CMS code, and the controler code. There is also a pretty cool table-object that can be used to deal with specific database tables.

Extender: The ultimate idea is for the core code to be broken out into modules, which have been divided up sanely. Something a little bit more like a micro-kernal approch. At this point it’s just not true, and the extender roll would be a hard and unsupported one. I do however intend to keep on cleaning this up.

Joes Goals Runs on Cold Fusion

I use a pretty nifty little website called joe’s goals to track some of the things in my life. It ties in rather nicely with the google personal homepage, and has served me well for more than two years. It’s crashing today, and from the look of it, it runs on cold fusion. I must admit, I’m a little surprised. (Not that I have anything against cold fusion, you just don’t see it that often these days)

Code Reviews

I recently attended a code review at Wharton. We’ve put together some code reviews at my job, but I know that Wharton has been doing formal code reviews for years and I wanted to check out their process to compare notes. For this particular code review they were looking at a small ColdFusion application developed using Squidhead.
Continue reading Code Reviews

Smarty prefilters need to have the compiled templates wiped to work.

I just thought I would drop this little tidbit to help save someone some time (hopefully). In the smarty template engine there is a pretty useful call “register_prefilter” which basically lets you pass a function to smarty that gets run on the whole template file before the template file itself has any of the substitutions made to it. This can be a god-send, however the first time you use it it probably won’t seem like it’s working. The secret is that you need to go into your templates_c directory, and dump all of the compiled templates every time you change the pre-filter.

Keeping your inbox empty in gMail

So a friend of mine recently convinced me to try using gmail in a different way. His suggestion was that I try archiving all of the mail that I have that no longer requires direct attention, or has some action I must take hanging on it. I have to admit its a pretty appealing idea, since the mail will still show up in searches and whatnot. Shortly following this suggestion I got put on a very high volume mailing list that I also wanted to read many of the emails on. So I decided to give it a try.

I started by setting a group “instant unarchive” on the first two-hundred emails that I have. Then I did the select all action, and clicked the link that appears at the top of your email list when you select all to “select all 70 billion emails” and archived the bunch. I then clicked on the left the “instant unarchive” group, and moved them to my inbox. Ta-Da now I’m down to my latest 200 emails in my inbox. As some of these are still relevent & outstanding I’m going to have to archive them by hand.

The concept of having an empty inbox is pretty darned appealing to me. I’ll give you updates as I go. (oh by the way, the command key to archive an email is “e”)

Why Doesn’t TinyMCE load in IE?

looks like it is all due to the insertAdjacentHTML call being used in another library. In my case, wz_tooltip. Oh wow did this hurt me. So that horror of a project that keeps on poking its head up sent in another small request… put tinyMCE or FCKeditor into one page on the website. Offered 5 hours. Well TinyMCE is already installed, so I figured this was a chance to recoup a little of my loss on this project. Sure enough, I activated TinyMCE with about 5 lines of code, checked that it worked in Firefox, and billed my money.

Next morning I get a call. The thing doesn’t work in IE. So I try a few quick and obvious things, move around where it gets loaded, try a few different load orders. No luck. Grr. I was going to type out my whole damn process, but I realized that’s not what people want to read…

Short version is: the wz_tooltip.js library conflicts with the TinyMCE library ONLY in Internet Explorer. This is because of a call to insertAdjacentHTML which is an IE-only javascript call (thanks again for embrace and extend M$). As a workaround, you can modify the wz_tooltip file by commenting out from line 397 (inclusive) (thats: if(wztt_body.insertAdjacentHTML) ) down to line 400 inclusive (thats : else if(typeof wztt_body.innerHTML != wztt_u && document.createElement && wztt_body.appendChild) ) And now I’m off to submit bug reports.

What a waste of a morning.

Generating iCal files with ColdFusion

I’ve been using ColdFusion to generate and mail iCal (*.ics) files. This should be a cinch, as they are really pretty simple text files. However, when I receive the file in Microsoft Outlook 2007, I have no options to add it to my calendar and I see the following message: “As the meeting organizer, you do not need to respond to the meeting.”

This is peculiar, as my address is not the organizer specified in the iCal file, it is only the recipient of the iCal attachment. I’m going to keep looking into it, but I thought I’d mention it here in case anyone else is running into the same issue.

The two functions I’ve found online to assist in generating iCal files are: