Consultar Estado de Panel - PHP Online

Form of PHP Sandbox

Enter Your PHP code here for testing/debugging in the Online PHP Sandbox. As in the usual PHP files, you can also add HTML, but do not forget to add the tag <?php in the places where the PHP script should be executed.

Name: Consultar Estado de Panel fullscreencopydownloadembedprint


Your result can be seen below.

Result of php executing





Full code of Consultar Estado de Panel.php

  1. <?php
  2.  
  3.      /*
  4.     $fecha = date('d/m/y');
  5.     $horaPeticionProtom = strtotime('now');
  6.     echo ("fecha: " . $fecha);
  7.     echo ("\n horaPeticionProtom: " . $horaPeticionProtom);
  8.     */
  9.     
  10.     //Valores devueltos por las operaciones de arriba ANTES de lanzar PROTOM:
  11.     /*
  12.     ValidateSaviaInstallation::sendSaviaInstallationCommand
  13.         <country>ES</country>
  14.         <numinst>1502597</numinst>
  15.         <panel>SDVECU</panel>
  16.         <mode>1</mode>
  17.         <maintenance>28239840</maintenance>
  18.         <version>2.33</version>
  19.         <transaction_id>M1358834261568630424</transaction_id>
  20.         <command_type>ConsultSystemTechnicalStatus_v08_08</command_type>
  21.         <sei>1</sei>
  22.  
  23.     */
  24.     
  25.     $fecha = date('24/10/19');
  26.     $horaPeticionProtom = '1571911629';
  27.     
  28.     //Valores devueltos por consulta AlarmLog
  29.     $fechaAlarmLog = "22/10/19";
  30.     $horaAlarmLog = "19:50:40";
  31.     
  32.     $resultAlarmLog = strtotime($horaAlarmLog);
  33.     if(strcasecmp($fecha, $fechaAlarmLog) == 0 && $resultAlarmLog > $horaPeticionProtom){
  34.         echo "Fuera de pruebas (CCS)";
  35.     }
  36.     else{
  37.         echo "En pruebas (ITS)";
  38.     }
  39.  
File Description
  • Consultar Estado de Panel
  • PHP Code
  • 24 Oct-2019
  • 1.1 Kb
You can Share it: