more code cleanup for VIP.
More escaping values and removing extract()