Example 1 — Hash a String
Pass a string in and get a 32-character hash back.
<?php
$hash = md5("hello");
echo $hash, PHP_EOL;
echo strlen($hash), PHP_EOL; How It Works
- Call md5 with a string. The text here is hello.
- Get a hex hash. It looks random but is always the same for this input.
- Count the length. strlen shows 32 characters.
- Rerun anytime. The same input gives the same hash every time.

