url shortener in php mysql, version 2 didn't feel like deleting/merging the first one and re structured everything