OK...in that case, try replacing $1 in the code with $2 (all occurences (sp?))