Merge branch 'master' of git://gitorious.org/laconica/br3nda into review/master

This commit is contained in:
CiaranG
2009-04-08 22:11:58 +01:00
4 changed files with 25 additions and 4 deletions

View File

@@ -1321,3 +1321,16 @@ function common_compatible_license($from, $to)
// XXX: better compatibility check needed here!
return ($from == $to);
}
/**
* returns a quoted table name, if required according to config
*/
function common_database_tablename($tablename)
{
if(common_config('db','quote_identifiers')) {
$tablename = '"'. $tablename .'"';
}
//table prefixes could be added here later
return $tablename;
}