Converting a jQuery Plugin into a WordPress Plugin