New functions

Added dbConnect and mailConnect
Changed connect to excecute both of them