corrected sql connect & navbar