    <?php 
    
  $consulta=ConsultarProducto($_GET['id']);

  function ConsultarProducto($id)
  {
    include 'conexion.php';
    $sentencia="SELECT * FROM publicidad WHERE id='".$id."' ";
    $resultado=$conexion->query($sentencia) or die ("Error consultar auto".mysqli_error($conexion));
    $filas=$resultado->fetch_assoc();
    return [
      $filas['titulo'],
      $filas['linea1'],
      $filas['linea2'],
      $filas['linea3'],
      $filas['linea4'],
      $filas['linea5'],
      $filas['linea6'],
      $filas['numero'],

    ];

  }
  
  
    
    
    include ('menuadm.php') ?>
    <!-- Our About -->
	<section class="ulockd-about-one">
		<div class="container">
			<div class="row">
				<div class="col-sm-12 col-md-6 col-md-offset-3">
					<div class="booking_form_style1 text-center">
		                <!-- Booking Form Sart-->
			            <form id="booking_form" class="booking_form text-center" name="booking_form"  action="publicidad2.php"  method="POST" enctype= "multipart/form-data" novalidate="novalidate">
			                 <input type="hidden" name="id" value="<?php echo $_GET['id']?> ">
			                <div class="messages"></div>
							<div class="row">
				                <div class="col-sm-12">
				                	<h3>Regitro de Participantes.</h3>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="titulo" class="col-md-1 control-label">Titulo:</label>
										<input id="titulo" name="titulo" class="form-control"  required="required" value="<?php echo $consulta[0] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                 <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="linea1" class="col-md-3 control-label">Linea 1:</label>
										<input id="linea1" name="linea1" class="form-control"  required="required" value="<?php echo $consulta[1] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="linea2" class="col-md-3 control-label">Linea 2:</label>
										<input id="linea2" name="linea2" class="form-control"  required="required" value="<?php echo $consulta[2] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="linea3" class="col-md-3 control-label">Linea 3:</label>
										<input id="linea3" name="linea3" class="form-control"  required="required" value="<?php echo $consulta[3] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="linea4" class="col-md-3 control-label">Linea 4:</label>
										<input id="linea4" name="linea4" class="form-control"  required="required" value="<?php echo $consulta[4] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="linea5" class="col-md-3 control-label">Linea 5:</label>
										<input id="linea5" name="linea5" class="form-control"  required="required" value="<?php echo $consulta[5] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="numero" class="col-md-3 control-label">Numero:</label>
										<input id="numero" name="numero" class="form-control"  required="required" value="<?php echo $consulta[7] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                <div class="col-sm-12">
				                    <div class="form-group">
				                        <label for="linea6" class="col-md-3 control-label">Linea 6:</label>
										<input id="linea6" name="linea6" class="form-control"  required="required" value="<?php echo $consulta[6] ?>"  type="text">
										<div class="help-block with-errors"></div>
									</div>
				                </div>
				                    <div class="form-group">
                    				<div class="col-md-offset-3 col-md-6">
                                          <button type="submit" class="btn btn-info">GUARDAR</button>
                                          <a href='inic_adm.php'class="btn btn-danger ">CANCELAR</a>
                                    </div>
				                </div>
			                </div>
			            </form>
					</div>
				</div>
			</div>
		</div>
	</section>

	<?php include ('pieadm.php') ?>


	
