<?php session_start();?>
<?php include('../_cfg/config.php');?>
<?php include('php_session.php');?>
<?php $widesc=$_POST['widesc']; ?>
<?php $orient=$_POST['orient']; ?>
<?php $version=$_POST['version']; ?>

<?php
$jwib_sql='select *, user_vida +user_mmae +user_estu +user_dpub +user_vari as modifica ';
$jwib_sql.='from user0 where user_codigo="'.$_SESSION['user_codigo'].'"';
$jwib_res=msql_query($jwib_sql,$link_vcrx);
$modifica= msql_result($jwib_res,0,'modifica');
?>

<?php $fsize=15?>
<?php $trbreak='';?>
<?php $tipomenu='';?>
<?php $maxmenu=2 ;?>
<?php //if($mobile=='true' and $orient=='V'){$fsize=40; echo '<br>';}?>
<?php //if($mobile=='true' and $orient=='H'){$fsize=15; $trbreak='</tr><tr><td style="font-size:4px;"></br></td></tr><tr>';}?>
<?php if($mobile=='true'){$desktop='false';$maxmenu=2;}else{$desktop='true';} ?>

<resul>
    <?php for($cmenu=1;$cmenu<=$maxmenu;$cmenu++){ ?>
    <?php if($cmenu==1){$tipomenu='_top';}else{$tipomenu='_left';}?>
    <?php if($mobile=='true' and $cmenu==1){$fsize=40;}?>
    <?php if($mobile=='true' and $cmenu==2){$fsize=15; $trbreak='</tr><tr><td style="font-size:4px;"></br></td></tr><tr>';}?>
    <menu<?php echo $tipomenu; ?>>
      <div style="display:none;" ><top1>PRINCIPAL</top1><top2>Principal</top2></div>

      <?php if($mobile=='true'){echo '<br>';}?>
      <table id="menu<?php echo $tipomenu; ?>" width ="100%" valign="middle" border=0 >
        <tr valign="middle" style="height:100%;">
            <?php //echo $trbreak; ?>
            <?php if($menu=='main'){?>
            <td valign="middle">
            <?php $pidtxt='mnu1_regi'; $pcaption='Registros'; $psize=$fsize; $ponclick='cont_regi();';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_cont'; $pcaption='Contabilidad'; $psize=$fsize; $ponclick='cont_info("cont");';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_rpu2'.$tipomenu; $pcaption='Discursantes'; $psize=$fsize; $ponclick='jwib_asig1("DPU2");'; include('vrbutton.php'); ?>
            </td>
            <?php if(mb_stristr('sist.admi',$_SESSION['user_tipo'])){ ?>
                <?php echo $trbreak; ?>
                <td valign="middle">
                <?php $pidtxt='mnu1_mant'; $pcaption='Mantenimiento'; $psize=$fsize; $ponclick='menu_main("mant");';  include('vrbutton.php'); ?>
                </td>
                <?php echo $trbreak; ?>
                <td valign="middle">
                <?php $pidtxt='mnu1_user'.$tipomenu; $pcaption='Usuarios'; $psize=$fsize; $ponclick='jwib_user("USER0");'; include('vrbutton.php'); ?>
                </td>
            <?php } ?>
            <?php if(mb_stristr('sist',$_SESSION['user_tipo'])){ ?>
                <?php echo $trbreak; ?>
                <td valign="middle">
                <?php $pidtxt='mnu1_data'; $pcaption='MySQL'; $psize=$fsize; $ponclick='menu_main("data");';  include('vrbutton.php'); ?>
                </td>
            <?php } ?>

            <?php } ?>

        
            <?php if($menu=='mant'){?>
            <div style="display:none;"><top1>Informes</top1><top2>Informes</top2></div>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_main'; $pcaption='Principal'; $psize=$fsize; $ponclick='menu_main();';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_user'; $pcaption='Usuarios'; $psize=$fsize; $ponclick='mant_user();';  include('vrbutton.php'); ?>
            </td>
            <?php if(mb_stristr('sist.admi',$_SESSION['user_tipo'])){ ?>
            <?php echo $trbreak; ?>
                <td valign="middle">
                <?php //$pidtxt='mnu1_acce'; $pcaption='Accesos'; $psize=$fsize; $ponclick='cont_acce();';  include('vrbutton.php'); ?>
                </td>
            <?php } ?>
            <?php } ?>

            <?php if($menu=='data'){?>
            <div style="display:none;"><top1>MySql</top1><top2>MySql</top2></div>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_main'; $pcaption='Principal'; $psize=$fsize; $ponclick='menu_main();';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_maes'; $pcaption='Tab.Master'; $psize=$fsize; $ponclick='set_data(0);';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_tran'; $pcaption='Tab.Transac.'; $psize=$fsize; $ponclick='set_data(1);';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_indx'; $pcaption='Ind.Master'; $psize=$fsize; $ponclick='set_data(2);';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_indx'; $pcaption='Ind.Transac'; $psize=$fsize; $ponclick='set_data(3);';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_view'; $pcaption='Vistas'; $psize=$fsize; $ponclick='set_data(4);';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_fill'; $pcaption='Listas'; $psize=$fsize; $ponclick='set_data(6);';  include('vrbutton.php'); ?>
            </td>
            <?php echo $trbreak; ?>
            <td valign="middle">
            <?php $pidtxt='mnu1_defa'; $pcaption='Default'; $psize=$fsize; $ponclick='set_data(7);';  include('vrbutton.php'); ?>
            </td>
            <?php } ?>
        </tr>
      </table>
    </menu<?php echo $tipomenu; ?>>
    <?php } ?>

</resul>

