<?php include 'security.php'; include '../../landing/actions/promos.php'; $promos = new promos(); extract($_GET); if (isset($id_promo)) { echo $promos->deleteID($id_promo); }
<?php extract($_GET); $edit = false; if (isset($id_promo)) { $edit = true; include '../landing/actions/promos.php'; $promos = new promos(); $a_data = $promos->loadDataID($id_promo); } ?> <div class="new-promo-container"> <img src="images/logo.jpg" class="logo" /> <div class="header white-text red-background">Crear promoción</div> <div class="new-promo-form"> <form id="myForm" > <table> <tr><td class="label">Nombre Promo:</td><td><input type="text" class="txtbox" id="txt_nombre" value="<?php if ($edit) { echo $a_data[0]['nombre_promo']; } ?> "></td></tr> <tr><td class="label">Bono USD:</td><td><input type="text" class="txtbox soloNumero" id="txt_valor_bono" value="<?php if ($edit) { echo $a_data[0]['valor_bono']; } ?> " ></td></tr> <tr><td class="label">Fecha Inicio:</td><td><input type="text" class="txtbox" id="txt_fecha_inicio" value="<?php if ($edit) {