Collections functions
Encryption functions
General functions
Theme permission functions
Resource functions

get_max_theme_levels()

Parameters

This function accepts no parameters.

Location

include/collections_functions.php lines 994 to 1009

Definition

 
function get_max_theme_levels(){
    
// return the maximum number of theme category levels (columns) present in the collection table
    
$sql "show columns from collection like 'theme%'";
    
$results sql_query($sql);
    foreach(
$results as $result) {
        if (
$result['Field'] == 'theme'){
            
$level 1;
        } else {
            
$thislevel substr($result['Field'],5);
            if (
is_numeric($thislevel) && $thislevel $level){
                
$level $thislevel;
            }
        }
    }
    return 
$level;
}

This article was last updated 5th July 2020 05:05 Europe/London time based on the source file dated 3rd July 2020 14:33 Europe/London time.