trying to get encoding to work