Unsupported operand types: int + string - Joomla 5

nemanja

Member
Hi, a got this error:
Thanks


Screenshot 2024-12-12 at 22-17-29 Error 0.png
 
And this:

$idiscCode = '{km___id}';

$db = JFactory::getDbo();
$query = $db->getQuery(true);
$query
->select('m.note, m.date_time, u.name')
->from('map_notes AS m')
->leftJoin('szh1d_users AS u ON u.id = m.userid')
->where('map_id = ' . $db->quote($idiscCode))
->order($db->quoteName('date_time') . ' DESC');

$db->setQuery($query);
$iused = $db->loadObjectList();

foreach ((array)$iused as $row)

{
$list[] = "<li>" . $row->name . "<br /><br />" . $row->date_time . "<br /><br />" . $row->note . "<br /><br /></li>";
}

return '{km___kunde_erreichbar}' . "" . implode(array_filter($list)) . "";
 
And this:

$idiscCode = '{km___id}';

$db = JFactory::getDbo();
$query = $db->getQuery(true);
$query
->select('m.note, m.date_time, u.name')
->from('map_notes AS m')
->leftJoin('szh1d_users AS u ON u.id = m.userid')
->where('map_id = ' . $db->quote($idiscCode))
->order($db->quoteName('date_time') . ' DESC');

$db->setQuery($query);
$iused = $db->loadObjectList();

foreach ((array)$iused as $row)

{
$list[] = "<li>" . $row->name . "<br /><br />" . $row->date_time . "<br /><br />" . $row->note . "<br /><br /></li>";
}

return '{km___kunde_erreichbar}' . "" . implode(array_filter($list)) . "";
But, here i dont have that
 
This is php, not Fabrik.
Which Joomla, Fabrik, php version are you running?

Which error do you get (after fixing your first code)?
 
Obviously the query is wrong.

Enable Fabrik Debug in Fabrik Options, append &fabrikdebug=1 to you list URL.
This should show some more infos.

Or debug your generated query and put it directly in phpMyAdmin.
 
An error has occurred.
1075 Incorrect table definition; there can be only one auto column and it must be defined as a key
 
I find, problem is with table prefix. Now i just got this errors, but list work.
Attached
 

Attachments

  • 1734045998244.png
    1734045998244.png
    668.4 KB · Views: 51
This is a MySQL error related to your table, see e.g.
https://mariadb.com/kb/en/e1075/

I assume you are not working with tables created by Fabrik but with external ones?
Make sure they are defined correctly.

Deprecated messages:
These are Joomla internal messages.. You will see them only with J!System debug enabled and logged in as admin.
 
Hi, I switched to J5 and installed a new Fabrik and then just uploaded the data. Thats all. I add ID as Primary, thanks.
 
Last edited:
When i try to ADD NEW or UPDATE data in fabrik i got now this error:
0 array_filter(): Argument #1 ($array) must be of type array, null given
 
Obviously this is also about your php code
" . implode(array_filter($list)) . "";

Again, this is php, not Fabrik.
 

Members online

No members online now.
Back
Top