Warning:mysql_connect () [Function.mysql-connect]: Can ' t connect to the local MySQL server through socket '/var/lib/mysql/mys Ql.sock ' (2) in/home/content/63/8523763/html/deng/fqlbnet/admin/inc/db.php on line 34
Can ' t connect to the local MySQL server through socket '/var/lib/mysql/mysql.sock ' (2)
Reference to a foreign website is a matter of privilege
Avenson & Root Privs to database Gallery2:
Grants for Root@localhost |
The code is as follows |
Copy Code |
+-------------------------------------------------------------------------------------------------------------- --------------------------+ | GRANT all Privileges "*.* to ' root" @ ' localhost ' identified by PASSWORD ' *8C4AC955DD6333EF4FB4F569301A21D9539567A1 ' with GRANT OPTION | | GRANT all privileges in ' Gallery2 '. * to ' root ' @ ' localhost ' |
Grants for Avenson@localhost |
+-------------------------------------------------------------------------------------------------------------- --+
The code is as follows |
Copy Code |
| GRANT USAGE on *.* to ' avenson ' @ ' localhost ' identified by PASSWORD ' *8C4AC955DD6333EF4FB4F569301A21D9539567A1 ' | | GRANT all privileges in ' Gallery2 '. * to ' avenson ' @ ' localhost ' |
Line 957 are the ElseIf line below (of this views/includes/handler.inc). I am using a godaddy msql (not msqli) db.
The code is as follows |
Copy Code |
Function Views_get_timezone () { global $user; if (variable_get (' Configurable_timezones ', 1) & amp;& $user->uid && strlen ($user->timezone)) { $timezone = $user->timezone ; } Else { $timezone = variable_get (' Date_default_timezone ', 0); } Set up the database timezone if (In_array ($GLOBALS [' Db_type '], array (' MySQL ', ' mysqli ', ' Pgsql ')) { $offset = ' +00:00 '; static $already _set = false; if (! $already _set) { if ($GLOBALS [' db_type '] = = ' Pgsql ') { Db_query ("SET time ZONE INTERVAL ' $offset ' HOUR to MINUTE"); } ElseIf ($GLOBALS [' db_type '] = = ' Mysqli ' | | version_compare (mysql_get_server_info (), ' 4.1.3 ', ' >= ')) { Db_query ("SET @ @session. Time_zone = ' $offset '"); } $already _set = true; } } return $timezone; } |