What are the differences between checksums, hashes, and encryption methods like md5 in the context of PHP programming?

Issue: Checksums, hashes, and encryption methods like md5 serve different purposes in PHP programming. Checksums are used to verify data integrity, hashes are used for data verification and security, and encryption methods like md5 are used to securely store and transmit sensitive information. PHP Code Snippet:

// Calculating checksum using CRC32
$data = "Hello World";
$checksum = crc32($data);
echo "Checksum: $checksum";

// Generating hash using MD5
$hash = md5($data);
echo "MD5 Hash: $hash";

// Encrypting data using AES encryption
$key = "my_secret_key";
$encrypted_data = openssl_encrypt($data, 'AES-256-CBC', $key, 0, 'my_initialization_vector');
echo "Encrypted Data: $encrypted_data";