Feature proposal #3690 » cbArrayToInts.patch
administrator/components/com_comprofiler/plugin.foundation.php | ||
---|---|---|
if ( checkJversion() >= 2 ) {
|
||
|
||
$user = JFactory::getUser( $userId );
|
||
$cmsAccess = array_unique( cbArrayToInts( $user->getAuthorisedViewLevels() ) );
|
||
$cmsAccess = array_unique( cbToArrayOfInt( $user->getAuthorisedViewLevels() ) );
|
||
|
||
// Keep backwards levels compatible: J1.6's 1 is CB's 0, 2 is 1, 3 is 2:
|
||
if ( $cb1xNumbering ) {
|
components/com_comprofiler/plugin/user/plug_pms_mypmspro/pms.mypmspro.php | ||
---|---|---|
. "\n FROM " . $_CB_database->NameQuote( '#__menu' )
|
||
. "\n WHERE " . $_CB_database->NameQuote( 'link' ) . " LIKE " . $_CB_database->Quote( $pmsurlBase . '%', false )
|
||
. "\n AND " . $_CB_database->NameQuote( 'published' ) . " = 1"
|
||
. "\n AND " . $_CB_database->NameQuote( 'access' ) . " IN ( " . implode( ',', cbArrayToInts( CBuser::getMyInstance()->getAuthorisedViewLevelsIds( ( checkJversion() >= 2 ? false : true ) ) ) ) . " )"
|
||
. "\n AND " . $_CB_database->NameQuote( 'access' ) . " IN ( " . implode( ',', cbToArrayOfInt( CBuser::getMyInstance()->getAuthorisedViewLevelsIds( ( checkJversion() >= 2 ? false : true ) ) ) ) . " )"
|
||
. ( checkJversion() >= 2 ? "\n AND " . $_CB_database->NameQuote( 'language' ) . " IN ( " . $_CB_database->Quote( $_CB_framework->getCfg( 'lang_tag' ) ) . ", '*', '' )" : null );
|
||
$_CB_database->setQuery( $query );
|
||
$pms_id = $_CB_database->loadResult();
|