PHP Classes

File: CoffeeCMS/contents/themes/cfnews/model/category.php

Recommend this page to a friend!
  Classes of James Brows   Coffee CMS   CoffeeCMS/contents/themes/cfnews/model/category.php   Download  
File: CoffeeCMS/contents/themes/cfnews/model/category.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Coffee CMS
Content management system using MVC based themes
Author: By
Last change:
Date: 2 years ago
Size: 611 bytes
 

Contents

Class file image Download
<?php


function menu_hasChild($menu_id)
{
   
$total=count(Configs::$_['sub_menu_data']);

    for (
$i=0; $i < $total; $i++) {
        if(
Configs::$_['sub_menu_data'][$i]['parent_menu_id']==$menu_id)
        {
            return
true;
        }
    }

    return
false;
}

function
menu_allChild($menu_id)
{
   
$total=count(Configs::$_['sub_menu_data']);

   
$result=array();

    for (
$i=0; $i < $total; $i++) {
        if(
Configs::$_['sub_menu_data'][$i]['parent_menu_id']==$menu_id)
        {
           
array_push($result, Configs::$_['sub_menu_data'][$i]);
        }
    }

    return
$result;
}