class SomeClass<br>
{<br>
...<br>
private function getErrorCodes() {<br>
$query = <<<SQL<br>
SELECT<br>
`code`<br>
FROM `table`<br>
...<br>
SQL;<br>
return DB->fetch_column($query);<br>
}<br>
...<br>
}<br>
class SomeClass<br>
{<br>
...<br>
private function getErrorCodes() {<br>
$query = "SELECT<br>
`code`<br>
FROM<br>
`table`<br>
...";<br>
return DB->fetch_column($query);<br>
}<br>
...<br>
}<br>
return DB->fetch_column('SELECT code FROM table ...');
$query = '
SELECT
code
FROM
table
WHERE
id = ?';
class SomeClass
{
...
private function getErrorCodes() {
$query = "SELECT"
. "`code` "
. "FROM "
. "`table` "
. "WHERE ...";
return DB->fetch_column($query);
}
...
}