【发布时间】:2013-01-22 12:44:18
【问题描述】:
大家好,在我的 getListQuery() 方法中,我的这个查询 en SQL 有错误,因为我不知道如何转义 $language 值
$query->from('`#__noticias` AS a');
$query->where('( a.idioma LIKE '.$language.' )');
我想得到这个。
$query->from('`#__noticias` AS a');
$query->where('( a.idioma LIKE "es-ES" )');
任何想法!
【问题讨论】:
-
投反对票,因为标签表示 SQL,但这里显然还有其他平台在起作用,因为那不是 SQL。
标签: joomla2.5