getContentBread($_GET['CONID'], $breadArr);
}
if (isset($_GET['SCID'])) {
    //Gen for last node to cat to module
    getSubCatBread($_GET['SCID'], $MID, $breadArr);
    getCatBread($_GET['CID'], $MID, $breadArr);
    getModuleBread($MID, $breadArr);
} else {
    if (isset($_GET['CID'])) {
        //Gen for cat to Module
        getCatBread($_GET['CID'], $MID, $breadArr);
        getModuleBread($MID, $breadArr);
    } else {
        if (isset($MID)) {
            //Gen only Module
            getModuleBread($MID, $breadArr);
        }
    }
}
$breadArr = array_reverse($breadArr);
foreach ($breadArr as $v) {
    echo $v;
}
echo '</ol>';
function getSubCatBread($scid, $mid, &$breadArr)
{
    $sqlStr = "select * from trn_content_sub_category where SUB_CONTENT_CAT_ID = " . $scid;
    $rs = mysql_query($sqlStr) or die(mysql_error());
    if ($_SESSION['LANG'] == 'TH') {
        $selectedColName = 'SUB_CONTENT_CAT_DESC_LOC';
    } else {
*/
if (isset($_GET['SCID'])) {
    //Gen for last node to cat to module
    $breadArr = "";
    getSubCatBread($_GET['SCID'], $_GET['MID'], $breadArr);
    getCatBread($_GET['CID'], $_GET['MID'], $breadArr);
    getModuleBread($_GET['MID'], $breadArr);
} else {
    if (isset($_GET['CID'])) {
        //Gen for cat to Module
        getCatBread($_GET['CID'], $_GET['MID'], $breadArr);
        getModuleBread($_GET['MID'], $breadArr);
    } else {
        if (isset($_GET['MID'])) {
            //Gen only Module
            getModuleBread($_GET['MID'], $breadArr);
        }
    }
}
$breadArr = array_reverse($breadArr);
foreach ($breadArr as $v) {
    echo $v;
    //	echo "Current value of \$breadArr: $v.\n";
}
echo '</ol>';
function getSubCatBread($scid, $mid, &$breadArr)
{
    $sqlStr = "select * from trn_content_sub_category where SUB_CONTENT_CAT_ID = " . $scid;
    $rs = mysql_query($sqlStr) or die(mysql_error());
    while ($row = mysql_fetch_array($rs)) {
        //echo count($breadArr);