token replacement script