re - 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.
Result of php executing
Full code of re.php
- <?php
- $json='[{
- "codeAnomalie": "00200",
- "libelleCourt": "En attente document(s) importation",
- "libelleLong": "En attente document(s) importation",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00200",
- "visible": true,
- "libelle": "En attente document(s) importation"
- },
- {
- "codeAnomalie": "00025",
- "libelleCourt": "Importation/échange UE animal moins de 15 semaines",
- "libelleLong": "Importation/échange UE animal moins de 15 semaines",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00025",
- "visible": true,
- "libelle": "Importation/échange UE animal moins de 15 semaines"
- },
- {
- "codeAnomalie": "00030",
- "libelleCourt": "Echange com.:Examen clinique absent ou non valide",
- "libelleLong": "Echange commercial UE : examen clinique absent ou non valide",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00030",
- "visible": true,
- "libelle": "Echange commercial UE : examen clinique absent ou non valide"
- },
- {
- "codeAnomalie": "00005",
- "libelleCourt": "Titrage antirabique absent ou non valide",
- "libelleLong": "Titrage antirabique absent ou non valide",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00005",
- "visible": true,
- "libelle": "Titrage antirabique absent ou non valide"
- },
- {
- "codeAnomalie": "00010",
- "libelleCourt": "Vaccination antirabique absente ou non valide",
- "libelleLong": "Vaccination antirabique absente ou non valide",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00010",
- "visible": true,
- "libelle": "Vaccination antirabique absente ou non valide"
- },
- {
- "codeAnomalie": "00015",
- "libelleCourt": "Vac. antirab. non valide, date inconnue sur sol fr",
- "libelleLong": "Vacinnation antirabique non valide et date arrivée sur le sol français inconnue",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00015",
- "visible": true,
- "libelle": "Vacinnation antirabique non valide et date arrivée sur le sol français inconnue"
- },
- {
- "codeAnomalie": "00020",
- "libelleCourt": "Sans document sanitaire officiel",
- "libelleLong": "Sans document sanitaire officiel",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00020",
- "visible": true,
- "libelle": "Sans document sanitaire officiel"
- },
- {
- "codeAnomalie": "00105",
- "libelleCourt": "Titrage antirabique absent ou non valide",
- "libelleLong": "Titrage antirabique absent ou non valide",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00105",
- "visible": true,
- "libelle": "Titrage antirabique absent ou non valide"
- },
- {
- "codeAnomalie": "00110",
- "libelleCourt": "Vaccination antirabique absente ou non valide",
- "libelleLong": "Vaccination antirabique absente ou non valide",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00110",
- "visible": true,
- "libelle": "Vaccination antirabique absente ou non valide"
- },
- {
- "codeAnomalie": "00115",
- "libelleCourt": "Aucun doc. animal sol français +6mois",
- "libelleLong": "Aucun document animal sol français +6mois",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00115",
- "visible": true,
- "libelle": "Aucun document animal sol français +6mois"
- },
- {
- "codeAnomalie": "00130",
- "libelleCourt": "Echange: examen clinique absent ou non valide",
- "libelleLong": "Echange: examen clinique absent ou non valide",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00130",
- "visible": true,
- "libelle": "Echange: examen clinique absent ou non valide"
- },
- {
- "codeAnomalie": "00035",
- "libelleCourt": "Animal introduit sur le sol français sans identif.",
- "libelleLong": "Animal introduit sur le sol français sans identification",
- "apms": true,
- "forImportation": false,
- "createCourrierCloture": true,
- "code": "00035",
- "visible": true,
- "libelle": "Animal introduit sur le sol français sans identification"
- },
- {
- "codeAnomalie": "00002",
- "libelleCourt": "Document sanitaire officiel non valide",
- "libelleLong": "Document sanitaire officiel non valide",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00002",
- "visible": true,
- "libelle": "Document sanitaire officiel non valide"
- },
- {
- "codeAnomalie": "00102",
- "libelleCourt": "Document sanitaire officiel non valide",
- "libelleLong": "Document sanitaire officiel non valide",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00102",
- "visible": true,
- "libelle": "Document sanitaire officiel non valide"
- },
- {
- "codeAnomalie": "00040",
- "libelleCourt": "Animal en présence d\'un animal sous APMS",
- "libelleLong": "Animal en présence d\'un animal sous APMS",
- "apms": true,
- "forImportation": false,
- "createCourrierCloture": true,
- "code": "00040",
- "visible": true,
- "libelle": "Animal en présence d\'un animal sous APMS"
- },
- {
- "codeAnomalie": "00045",
- "libelleCourt": "Pas de docu. sanitaire officiel envoyé sous 15 jrs",
- "libelleLong": "Pas de document sanitaire officiel envoyé sous 15 jrs (pays tiers)",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00045",
- "visible": true,
- "libelle": "Pas de document sanitaire officiel envoyé sous 15 jrs (pays tiers)"
- },
- {
- "codeAnomalie": "00050",
- "libelleCourt": "Importation : DVCE absent",
- "libelleLong": "Importation : DVCE absent",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00050",
- "visible": true,
- "libelle": "Importation : DVCE absent"
- },
- {
- "codeAnomalie": "00055",
- "libelleCourt": "DVCE NC, animaux enregistrés > nbre inscrit DVCE",
- "libelleLong": "DVCE NC, animaux enregistrés > nbre inscrit DVCE",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00055",
- "visible": true,
- "libelle": "DVCE NC, animaux enregistrés > nbre inscrit DVCE"
- },
- {
- "codeAnomalie": "00125",
- "libelleCourt": "Importation/échange UE animal moins de 15 semaines",
- "libelleLong": "Importation/échange UE animal moins de 15 semaines",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00125",
- "visible": true,
- "libelle": "Importation/échange UE animal moins de 15 semaines"
- },
- {
- "codeAnomalie": "00060",
- "libelleCourt": "Vaccination antirabique réalisée avant 12 semaines",
- "libelleLong": "Vaccination antirabique réalisée avant 12 semaines",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00060",
- "visible": true,
- "libelle": "Vaccination antirabique réalisée avant 12 semaines"
- },
- {
- "codeAnomalie": "00065",
- "libelleCourt": "Vaccination non valide: délai de 21jr non respecté",
- "libelleLong": "Vaccination non valide: délai de 21jr non respecté",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00065",
- "visible": true,
- "libelle": "Vaccination non valide: délai de 21jr non respecté"
- },
- {
- "codeAnomalie": "00160",
- "libelleCourt": "Vaccination antirabique réalisée avant 12 semaines",
- "libelleLong": "Vaccination antirabique réalisée avant 12 semaines",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00160",
- "visible": true,
- "libelle": "Vaccination antirabique réalisée avant 12 semaines"
- },
- {
- "codeAnomalie": "00165",
- "libelleCourt": "Vaccination non valide: délai de 21jr non respecté",
- "libelleLong": "Vaccination non valide: délai de 21jr non respecté",
- "apms": false,
- "forImportation": true,
- "createCourrierCloture": false,
- "code": "00165",
- "visible": true,
- "libelle": "Vaccination non valide: délai de 21jr non respecté"
- },
- {
- "codeAnomalie": "00046",
- "libelleCourt": "Pas de passeport envoyé sous 1 mois (UE)",
- "libelleLong": "Pas de passeport envoyé sous 1 mois (UE)",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00046",
- "visible": true,
- "libelle": "Pas de passeport envoyé sous 1 mois (UE)"
- },
- {
- "codeAnomalie": "00300",
- "libelleCourt": "Symptômes de rage",
- "libelleLong": "Animal avec des symptômes de la rage",
- "apms": true,
- "forImportation": true,
- "createCourrierCloture": true,
- "code": "00300",
- "visible": true,
- "libelle": "Animal avec des symptômes de la rage"
- },
- {
- "codeAnomalie": "00042",
- "libelleCourt": "Animal retour en France en sit. sanit. non valide",
- "libelleLong": "Animal de retour en France en situation sanitaire non valide",
- "apms": true,
- "forImportation": false,
- "createCourrierCloture": true,
- "code": "00042",
- "visible": true,
- "libelle": "Animal de retour en France en situation sanitaire non valide"
- }]';
- $a=json_decode($json);
- foreach($a as $b){
- echo "INSERT INTO anomaly_parameter (shortlabel,label,code)VALUES('".$b['libelleCourt']."','".$b['libelle']."','".$b['code']."');";
- }
- }
- }