<?php
// Define your allowed domains
$allowedDomains = ['197.242.157.252'];
// Get the client's Request Origin
if (isset($_SERVER['HTTP_ORIGIN'])) {
    $origin = $_SERVER['HTTP_ORIGIN'];
} else {
    $origin = $_SERVER['REMOTE_ADDR'];
}
// Validate against your whitelist
foreach ($allowedDomains as $domain) {
    if (strpos($origin, $domain) !== false) {
        if ($_POST['client_code'] == 'LVNT') {
            echo "LVNT-ECRYPTIO!@#";
        }
        exit(); // Exit immediately since authorization has been confirmed.
    }
}

// Unauthorized Access Detected 
// Optionally redirect, log error, etc.
echo "Not Authorized";
?>