-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathedit_lugar.php
167 lines (132 loc) · 4.73 KB
/
edit_lugar.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
<!DOCTYPE html>
<html lang="es">
<head>
<title>Editar Lugar</title>
<meta charset="UTF-8"/>
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
<link href="css/lug.css" media="all" rel="stylesheet" type="text/css" />
<script>
function myFunction() {
confirm("Presiona OK si deseas BORRAR!");
}
</script>
<!--<link href="login1.html" rel="import" />-->
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
<link href="http://cdn.phpoll.com/css/animate.css" rel="stylesheet">
<script src="js/lug.js" type="text/javascript"></script>
<!-- Latest compiled and minified JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
</head>
<?php
include('header.php');
?>
<?php include('conexion.php'); ?>
<?php
include ('conexion.php');
//include ('functions.php');
session_start();
if(isset($_SESSION['u_emp'])){
$rut=$_SESSION['u_emp'];
$sql="SELECT representante_legal from empresario where rut='$rut'";
$proc=mysqli_query($mysqli,$sql);
$resultado = mysqli_fetch_array($proc,MYSQL_ASSOC);
}
else{
header("Location: panel_e.php");
}
?>
<?php
$edt = $_POST['chupalo'];
$newquery= "SELECT * FROM lugar WHERE id_lugar='$edt'";
$p11= mysqli_query($mysqli,$newquery);
$resu= mysqli_fetch_array($p11,MYSQL_ASSOC);
?>
<!-- Page Content -->
<div id="bodyContent" class="container">
<div class="row">
<div class="col-md-9">
<form class="form-horizontal" method="post" action="ac.php">
<fieldset>
<!-- Form Name -->
<legend>Editar Lugar</legend>
<!-- File Button -->
<!-- Text input-->
<div class="form-group">
<label class="col-md-4 control-label" for="textinput">Nombre Lugar</label>
<div class="col-md-4">
<input id="textinput" name="nl" type="text" class="form-control input-md" value="<?php echo $resu['nombre'];?>" >
</div>
</div>
<!-- Multiple Checkboxes -->
<div class="form-group">
<label class="col-md-4 control-label" for="checkboxes">Categorias</label>
<div class="col-md-4">
<div class="checkbox">
<label for="checkboxes-0">
<input type="checkbox" name="ch[]" id="checkboxes-0" value="Agencias de Viaje y Tour Operador">
Agencias de Viaje y Tour Operador
</label>
</div>
<div class="checkbox">
<label for="checkboxes-1">
<input type="checkbox" name="ch[]" id="checkboxes-1" value="Guías de Turismo">
Guías de Turismo
</label>
</div>
<div class="checkbox">
<label for="checkboxes-2">
<input type="checkbox" name="ch[]" id="checkboxes-2" value="Servicios de Esparcimiento">
Servicios de Esparcimiento
</label>
</div>
<div class="checkbox">
<label for="checkboxes-3">
<input type="checkbox" name="ch[]" id="checkboxes-3" value="Alojamiento Turístico">
Alojamiento Turístico
</label>
</div>
<div class="checkbox">
<label for="checkboxes-4">
<input type="checkbox" name="ch[]" id="checkboxes-4" value="Artesanía">
Artesanía
</label>
</div>
</div>
</div>
<!-- Textarea -->
<div class="form-group">
<label class="col-md-4 control-label" for="textarea">Descripción</label>
<div class="col-md-4">
<textarea class="form-control" id="textarea" name="desc" style="width:200%;height:150px"><?php echo $resu['descripcion'];?></textarea>
</div>
</div>
<!-- Button -->
<!-- Select Basic -->
<div class="form-group">
<label class="col-md-4 control-label" for="selectbasic">Selecciona Comuna</label>
<div class="col-md-4">
<select id="selectbasic" name="comuna" class="form-control">
<option value="ARAUCO">ARAUCO</option>
<option value="LEBU">LEBU</option>
<option value="CAÑETE">CAÑETE</option>
<option value="CONTULMO">CONTULMO</option>
<option value="CURANILAHUE">CURANILAHUE</option>
<option value="LOS ALAMOS">LOS ALAMOS</option>
<option value="TIRUA">TIRUA</option>
</select>
</div>
</div>
<div class="form-group">
<div class="col-md-9">
<input type="hidden" name="edtlg" value="<?php echo $edt ?>">
<button type="submit" class="btn btn-success pull-right">Guardar</button><br/><br/>
<button type="submit" onclick="myFunction()" name="deletear" value="delete" class="btn btn-danger pull-right">Borrar</button>
</div>
</div>
</fieldset>
</form>
</div>
</div>
<script src="js/bootstrap.min.js"></script>
</html>