For running J!5.1 you must https://fabrikar.com/forums/index.php?wiki/update-from-github/ or include the new file manually https://fabrikar.com/forums/index.php?threads/joomla-5-1-and-fabrik-cannot-find-files-error.54473/post-285151 See also Announcements
Please see our announcement here.
_ at the end is looking strange, is this your element name? Not sure if this may create issues.{gls_fejlmelding___Oprettet_bruger_navn_}
// Get the database
$db = JFactory::getDbo();
// The current logged in Joomla user
$user = JFactory::getUser();
// Get the query
$query = $db->getQuery(true);
// Build the query
$query->select('Adresse')->from('kunde_profil')->where('user_id = ' . (int) $user->get('id');
Assign the query to the database
$db->setQuery($query);
// Load the first matched row's Adresse column
return $db->loadResult();
hi
The placeholders (the text inside the {} brackets) will only work for data in the current list. How is the data in the table kunde_profil related to this list's element? Is it that you want to include the current logged in user's 'address' that they have stored in that list?
If that's the case you will need to use some additional PHP to get that.
Lets presume that you have a field in kunde_profil called 'user_id' which stores the user's id. You will need to run a query to get the 'Adresse' for that user:
PHP:// Get the database $db = JFactory::getDbo(); // The current logged in Joomla user $user = JFactory::getUser(); // Get the query $query = $db->getQuery(true); // Build the query $query->select('Adresse')->from('kunde_profil')->where('user_id = ' . (int) $user->get('id'); Assign the query to the database $db->setQuery($query); // Load the first matched row's Adresse column return $db->loadResult();