Add files via upload
This commit is contained in:
parent
44fe6593ec
commit
04305d2c79
@ -18,6 +18,8 @@
|
||||
VALUES ( '%d', '%s', '%d', '%s')",
|
||||
$id, $tittle, $duration, $language);
|
||||
|
||||
$resul = mysqli_query($this->mysqli, $sql) or die ('Error into query database');
|
||||
|
||||
return $sql;
|
||||
}
|
||||
|
||||
@ -34,6 +36,10 @@
|
||||
$sql = sprintf( "SELECT * FROM film ");
|
||||
$resul = mysqli_query($this->mysqli, $sql) or die ('Error into query database');
|
||||
|
||||
while($fila=mysqli_fetch_array($resul)){
|
||||
$films[] = $this->loadFilm($fila["id"], $fila["tittle"], $fila["duration"], $fila["language"], $fila["description"]);
|
||||
}
|
||||
|
||||
return $resul;
|
||||
}
|
||||
|
||||
@ -69,7 +75,7 @@
|
||||
return $resul;
|
||||
}
|
||||
|
||||
|
||||
//Edit a film.
|
||||
public function editFilm($id, $tittle, $duration, $language,$description){
|
||||
$sql = sprintf( "UPDATE film SET tittle = '%s' , duration = '%d', language ='%s' , description ='%s'
|
||||
WHERE film.id = '%d';",
|
||||
|
Loading…
Reference in New Issue
Block a user