[TYPO3-dev] include_once(PATH_site .'typo3conf/localconf.php');
Martin Ficzel
martin.ficzel at gmx.de
Wed Nov 29 11:00:21 CET 2006
Tapio Markula schrieb:
> $dbConn=mysql_connect($dtypo_db_host,$typo_db_username,$typo_db_password);
>
>> $GLOBAL['TYPO3_DB'] objects exists, the localconf.php must have been
>> loaded before.
>>
>> $GLOBALS['TYPO3_DB'] has a 'link' variable: $GLOBALS['TYPO3_DB']->link
>> You can use this for your special commands like this:
>> $res = mysql_query($yourQueryString, $GLOBALS['TYPO3_DB']->link);
>
> ok. I made at that way - worked. Thank's :).
the $GLOBAL['TYPO3_DB'] can also handle update-querys as seen in the api
t3lib_DB.exec_UPDATEquery (
$ table,
$ where,
$ fields_values,
$ no_quote_fields = FALSE
)
that way you can alter your records and still work dbal-safe.
regards Martin
More information about the TYPO3-dev
mailing list