Fixing session construct error "Warning: session_start(): Cannot send session cookie - headers already send"