<?php
 
session_start();
include("DMMYSQLG.php");
include("DSA1000.php");
include("DMMYSQLG.php");

?>
<?php

$sq_invent=mysqli_query($con ,"SELECT  dgbasico.gpo_basico as idGru, dgbasico.des_basico as desGru FROM dginvent INNER JOIN dgbasico ON(dgbasico.gpo_basico=dginvent.gpo_basico) where dginvent.afe_inv='S' group by  dginvent.gpo_basico order by dgbasico.des_basico asc");
?>
<link rel="stylesheet" href="css/stylo.css" type="text/css"/>
<link rel="stylesheet" href="css/links.css" type="text/css"/>


<table height="100" align="left"style="#FFFFFF">
<?php

	$canProLin=7;
	$nGru=0;
	while($dt_invent=mysqli_fetch_array($sq_invent)){
		$nGru++;
		if($nGru==1)
			echo '<tr>';
			
		echo '<td  width="80" height="100" background="img_punt/lineas/boton.png">';
		echo '<p align="center">
			
				</a>
			  <p align="center" class="style8">
			  	<a href="productospre.php?idp='.date('himsdmY').'&idg='.$dt_invent['idGru'].'" class="Estilo4">
					
				'.$dt_invent['desGru'].'
				</a>
    		  <p align="center" class="style8">
			  </p>';
		echo '</td>';	
		if($nGru%$canProLin==0){
			echo '</tr>';
			$nGru=0;
		}
		
	}
	if(mysqli_num_rows($sq_invent)>0)for($i=($nGru+1);$i<=$canProLin;$i++){
		if($i==1)
			echo '<tr>';
		echo '<td  width="80" height="100" background="img_punt/lineas/boton.png">';
		echo '</td>';	
		if($i%$canProLin==0){
			echo '</tr>';
		}	
	}
?>

</table>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>