<html>
<head>
<title>DB Backup</title>
</head>
		<link href="../estilos/estilos.css" type="text/css" rel="stylesheet">

<CENTER>
<BR>
 <style type="text/css">
      body {
	padding-top: 40px;
	padding-bottom: 40px;
	background-color: #f5f5f5;
	background-image: url(../img/fondoP.jpg);
      }
	  
	   </style>
<?php
include("../conexion.php");

//mysql_connect($host, $user, $pw);
//$result_handle = mysql_list_dbs () or die ("mysql_list_dbs() failed with this error message: '" . mysql_error () . "'");

//$number_rows = mysql_num_rows ($result_handle);
$number_rows = "softcomcr_servicentro_covasur";
$repopt = $_POST['repopt'];
$sicher = $_POST['sicher'];
?>

  <body>
<form name="frepopt" action="<? echo $PHP_SELF ?>" method="POST">
<input type="hidden" name="repopt" value="1">
<select name="db_namero">
<?php
for ($oindex=0; $oindex < $number_rows; ++$oindex)
{
 $v_option = mysql_result ($result_handle, $oindex, 0);
?>
 <option value="<? echo $v_option; ?>"><? echo $v_option; ?></option>
<?php
}
?>
</select>
<input type="submit" name="submit" class="button" value="Reparar y Optimizar Tablas" style="width: 200px;">
</form>
<?php
if($repopt)
{
//  echo "repopt";
 include('syrepopt.php');
 $repopt="";
}
?>
<BR>
<HR>
<BR>
<?php
//mysql_connect($host, $user, $pw);
//$result_handle = mysql_list_dbs () or die ("mysql_list_dbs() failed with this error message: '" . mysql_error () . "'");
//$number_rows = mysql_num_rows ($result_handle);
?>
<form name="fsicher" action="<? echo $PHP_SELF ?>" method="POST">
<input type="hidden" name="sicher" value="1">
<select name="db_namesi">
<?php
for ($oindex=0; $oindex < $number_rows; ++$oindex)
{
 $v_option = mysql_result ($result_handle, $oindex, 0);
?>
 <option value="<? echo $v_option; ?>"><? echo $v_option; ?></option>
<?php
}
?>
</select>
<input name="submit" type="submit" class="button" style="width: 200px;" value="Respaldar Base de Datos">
</form>
<?php
if($sicher)
{
//  echo "sicher";
 include('sysicher.php');
 $sicher="";
}
?>
<BR>
</body></CENTER>

</html>
