$categories[] = $category->id;
    }
}
$cat = new Category_Model(1);
//outputs the tree structure in a un-ordered html list
echo $cat->get_descendants_chk($categories);
?>
				
				</td>
			</tr>
			
			<tr>
				<td><label for="">Packagings</label></td>
				<td>
					<?php 
$ppModel = new Products_packaging_Model(1);
echo $ppModel->getPackagingsByProduct($product->id);
?>
				
				</td>
			</tr>
			<tr>
				<td><label for="">Bars Groups [MCB only]</label></td>
				<td>
					<input type="checkbox" name="bar_size" value="1"> 14x8 size bars <br>
					<input type="checkbox" name="bar_size" value="2"> 175x175 bars <br>
					<input type="checkbox" name="bar_size" value="3"> 2x5 bars <br>
					<input type="checkbox" name="bar_size" value="4"> 4x6 or 2x3 bars <br>
					<input type="checkbox" name="bar_size" value="5"> 9x5 bars <br>
				</td>
			</tr>
echo htmlspecialchars($packaging->name);
?>
" /></td>
			</tr>
			<tr>
				<td><label for="packagingDescription">Description</label></td>
				<td><textarea name="packagingDescription" id="packagingDescription" class="formText"><?php 
echo $packaging->description;
?>
</textarea></td>
			</tr>	
			<tr>
				<td><label for="">Products</label></td>
				<td>
					<?php 
$ppModel = new Products_packaging_Model(1);
echo $ppModel->getProductsByPackaging($packaging->id);
?>
				
				</td>
			</tr>
			<tr>
				<td><label for="">Image</label></td>
				<td>
					<?php 
if ($packaging->image) {
    ?>
 
							<img src="/env/packaging_images/<?php 
    echo $packaging->image;
    ?>