tags:

views:

88

answers:

4

i have a code

<div class="b4_content">
    <div class="col_left3 FloatLeft">
        <h3>Clients / Projects</h3>
        <div id="left_menu" class="left_menu">
          <?php
            require("admin/Connection/connection.php");
            require("admin/functions/functions.php");
            $toplvl=0;
            /* 1st include of linkCategory.php */
            include "admin/functions/linkCategory.php";
          ?>
        </div>
    </div>
    <div class="col_right3 FloatRight ">
        <div class="cright_padd">
          <?php
            $uploader="admin/";
            $catID = $_GET['catID'];        
            if($catID==""){
                $toplvl=2;
                /* 2nd include of linkCategory.php */
                include "admin/functions/linkCategory.php";
            } else {
                $toplvl=0;
                include "admin/functions/viewImages.php";
            }
          ?>
        </div>
    </div>
    <div class="ClearBoth"></div>
</div>

As you can see i have 2 includes (admin/functions/linkCategory.php) with same pages My Problem is, the second include "admin/functions/linkCategory.php" does not show up.

Can you help me out

+1  A: 

My guess is that $catID is NOT equal to the empty string.

And btw, bolding doesn't work inside code blocks (if that's what you were trying to do).

Mark
It is an empty string. coz i tried echoing inside the condition
Treby
yah im tried to bold it.. hehe
Treby
+2  A: 

I guess $toplvl is a flag that's used within "admin/functions/linkCategory.php" to do different things. So, maybe the error isn't in this chunk, but in linkCategory.php itself.

Scott Herbert
Man your right.. nice guess.. i had a function in linkCategory.php, calling it twice will duplicate the created function. Thanks man. your thought helps.
Treby
That's the reason why I asked you to post linkCategory.php. :-) I gave +1 to Scott!
A: 

As an alternative, wrap whatever linkCategory.php outputs in a function. Include linkCategory.php once and replace the includes with a call to the function.

outis
A: 

if the problem still persists, you could set error reporting to show all and see if there's any output

Raz