Add case-insensitive string comparison for $last and $divoutput parameters - allows 'y' or 'Y' to be passed and still work!