PHP

Verify a reCAPTCHA using PHP 8.3

Here’s a PHP 8.3 function to verify a reCAPTCHA response with Google’s server. Ensure you replace YOUR_SECRET_KEY with your actual reCAPTCHA secret key. Explanation: Notes:

Loading

Read More
PHP

What is PHP?

PHP is a popular open-source scripting language primarily used for web development and creating dynamic content for websites. Here’s a brief overview: Here’s a simple example of PHP code: This script would output “Hello, World!” on the webpage when executed on a server with PHP installed. PHP has evolved over the years to support more […]

Loading

Read More
PHP

How to request an A record from a DNS server in PHP 8.3

In PHP 8.3, you can use the dns_get_record() function to query DNS records, including A records. Here’s an example of how to request an A record from a DNS server: Explanation: Example Output: If the domain has A records, the output will look like this:

Loading

Read More
PHP

How do I reverse an IP address for use in DNS BL?

Here’s a small function in PHP 8.3 that reverses an IPv4 address: Explanation: This ensures the function works safely and as expected.

Loading

Read More
Linux

Has Linux fixed the unix time bug yet?

The “Year 2038 problem” (also known as the 32-bit Unix time overflow bug) has largely been addressed in modern Linux systems and related software. So yes it has been fixed. Background on the Problem The issue arises because Unix time (the number of seconds since January 1, 1970, 00:00:00 UTC) is traditionally stored as a […]

Loading

Read More
Postfix

How do I block a domain name in postfix?

To block a domain name in Postfix, you can use the sender_access feature to reject emails from specific domains. Here’s a step-by-step guide: 1. Edit Postfix Configuration Open the main configuration file: Look for the smtpd_sender_restrictions line. If it doesn’t exist, add it, or modify it to include the check_sender_access directive: The permit ensures valid […]

Loading

Read More
PHP

Temperature conversions between Celsius and Fahrenheit using PHP.

Here’s an example of a PHP 8.2 class that handles temperature conversions between Celsius (C) and Fahrenheit (F): This class provides two static methods: The example usage demonstrates how to use the class to perform conversions. Let me know if you’d like to expand this functionality!

Loading

Read More
Wordpress

How to add a Google Form into a WordPress page.

To embed a Google Form into a WordPress page using HTML, follow these steps: 1. Get the Embed Code from Google Forms: 2. Edit Your WordPress Page: 3. Add the Embed Code: 4. Save and Publish: Example Embed Code. Here’s an example of what the embed code looks like: Customization. Additional Notes:. This method ensures […]

Loading

Read More
Dribble

ESPs: Why IP and Domain Reputation Matter and How to Manage Them

As an email service provider (ESP), your aim is to maintain a safe and trustworthy network for email senders (and their recipients) while ensuring they achieve high deliverability rates. A task that is no mean feat when you’re servicing a bank of customers with hundreds of thousands of IPs and domains – each with a […]

Loading

Read More
PHP

How to get country codes using the ODOO xmlrpc API and PHP.

To fetch country codes from an Odoo instance using PHP 8.2, you’ll need to use the Odoo XML-RPC API. Below is an example of how to achieve this: Step 1: Set Up PHP Environment Ensure you have PHP 8.2 installed with the necessary extensions, including the cURL extension, which is used for making HTTP requests. […]

Loading

Read More