But that's the easiest way of earning SO points! :(


On Fri, Jan 11, 2013 at 4:04 PM, ADmad <notifications@github.com> wrote:

> In app/View/Pages/home.ctp:
>
> > @@ -99,6 +99,13 @@ if (isset($filePresent)):
> >  		$connected = ConnectionManager::getDataSource('default');
> >  	} catch (Exception $connectionError) {
> >  		$connected = false;
> > +		$errorMsg = $connectionError->getMessage();
> > +		if (method_exists($connectionError, 'getAttributes')) {
> > +			$attributes = $connectionError->getAttributes();
> > +			if (isset($errorMsg['message'])) {
> > +				$errorMsg .= '<br />' . $attributes['message'];
> > +			}
> > +		}
>
> And hopefully it will reduce the numerous posts on SO and IRC asking why
> can't cake connect to db. It's surprisingly common so many people don't
> even have the required pdo driver installed for the db they are trying to
> connect to.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/cakephp/cakephp/pull/1068/files#r2618763>.
>
>