rewrote script for spaces to underscores