Support Company name Name Email Phone Comment function get_user_ip() { // Get the IP directly $user_ip = $_SERVER['REMOTE_ADDR']; return $user_ip; } function ip_check_shortcode() { $user_ip = get_user_ip(); if ($user_ip == '122.179.30.179') { return 'disabled'; // This will return a "disabled" class for use in JavaScript } else { return ''; // If not the target IP, it won't modify the button } } add_shortcode('check_user_ip', 'ip_check_shortcode'); // Get the value of the IP check from the shortcode var ip_check = ''; // Check if the IP address matches the condition (127.25.25.26) if (ip_check == 'disabled') { // Disable the submit button document.getElementById('submit-button').disabled = true; document.getElementById('submit-button').value = 'Submit Disabled'; // Optional: Change the button text }