Browsed by
Author: Jon Steege

Ariel Announces K24 Atom!

Ariel Announces K24 Atom!

k24ArielAtom
k24ArielAtom

Ariel and TMI Autotech today announced a new 2.4L K-series Honda powered Ariel Atom. This engine upgrade will likely give the base Atom 200hp and likely around 160 lb/ft of torque, if they use the k24 found in the TSX. These numbers might come in slightly lower if they choose the k24 found in the more common Accord, but that would make no sense.

The base model K20 powered Atom is still a rocket ship, so the new powerplant upgrade is a welcome surprise for anyone in the market for an Atom with their eye more on the base model. No word yet on whether Ariel and TMI will be offering the supercharged K24 as an option yet. Here is to hoping!

A Couple Spring Freemarker Binding Tags are Broken..

A Couple Spring Freemarker Binding Tags are Broken..

Java Spring binding tags for checkboxes and multiselect lists are broken in the Spring freemarker template.

I found this out after spending a large amount of time trying to determine why my simple validation to check for completion of required fields kept breaking on page reload after an error was found. I discovered there is an issue with the spring freemarker template macro named formMultiSelect and also in the formCheckboxes macro.

The issue is in the line determining if there is a previous selection made on the checkbox or multi-select. The check doesn’t properly dereference the variable containing the pre-selected values, and so attempts to deal with it as a string rather than an array, which causes an error similar to “freemarker.runtime – Expected collection or sequence. list evaluated instead to freemarker.template.SimpleScalar on line 368, column 12 in spring.ftl.”

The error can be corrected by copying their binding macro and modifying it to properly dereference the object in the routine to check existing values. In my case, the following line:

<#assign isSelected = contains(status.value?default([""]), value)>

became:

<#assign isSelected = contains(status.actualValue?default([""]), value)>

This change needs to be done in both the checkboxes macro as well as the formMultiSelect macro. This change allows the reload of the page to work properly after an error occurs, or if preliminary choices are made in the multi-select or checkboxes.

How to convert a .dbk file to a vCard .vcf file

How to convert a .dbk file to a vCard .vcf file

Recently I obtained a new cellphone and had a major issue trying to export my existing contacts to the new phone. I was left with a .dbk file which apparently is not very common and a rather strange file type. I just wanted to convert it to a .csv or a vCard file so I could import it where I needed the contact list to go. Since it took me a while to figure out how to do this, with much internet searching and false leads, I decided to write up the process I used to succesfully convert the file to a .vcf file:

  1. Rename the .dbk file to a .zip file
    1. for example, I had a test.dbk file, which I renamed to test.zip
  2. unzip the zip file
  3. within the unzipped folder, you will likely find several files, one of which will be a contacts.vcf