Hi,
Community Builder version 2.8.0+build.2023.03.17.19.11.55.64386eb8d
i have a number of Community Builder lists.
I have one with an id of 4, that has no menu associated with it
I have another with an id of 46, that has a menu associated with it with itemid=540
When community builder displays the list of lists on the frontend, trying to go to list with id=4 gives me list 46 instead.
This query in getCBprofileItemid in LegacyFoundationFunctions.php seems to be the problem:
$query = 'SELECT ' . $_CB_database->NameQuote( 'id' )
. "\n FROM " . $_CB_database->NameQuote( '#__menu' )
. "\n WHERE ( " . $_CB_database->NameQuote( 'link' ) . " LIKE " . $_CB_database->Quote( 'index.php?option=com_comprofiler&view=' . $_CB_database->getEscaped( $view, true ) . $additional . '%', false )
. ' OR ' . $_CB_database->NameQuote( 'link' ) . ' LIKE ' . $_CB_database->Quote( 'index.php?option=com_comprofiler&task=' . $_CB_database->getEscaped( $view, true ) . $additional . '%', false ) . ' )'
. $queryAccess;getCBprofileItemid view=userslist additional=&listid=4
The like clause means looking for listid=4 returns 46 instead!
I've fixed this by changing all the ids of my lists in the database to ensure no clashes!
Thanks
Jeff