sqlGetFromDB

The sqlGetFromDB hook is triggered when parsing the current database definition. It passes the generated SQL definitions and expects the same as return value.

Available

from Contao 2.11.0-rc2.

Parameters

  1. array $arrSql

    The compiled SQL definitions.

Return Values

Return $arrSql after adding your custom definitions.

Example

<?php

// config.php
$GLOBALS['TL_HOOKS']['sqlGetFromDB'][] = array('MyClass', 'mySqlGetFromDB');

// MyClass.php
public function mySqlGetFromDB($arrSql)
{
    // Modify the array of SQL statements

    return $arrSql;
}

More information

References

See also

results matching ""

    No results matching ""