E1.php

<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> </head> <body> <?php function Lengte($woord) { if (strlen($woord) > 10) { return substr_replace($woord, '...', 8); } else { return $woord; } } $woord = "12345678910"; echo Lengte($woord); ?> </body> </html>

Resultaat

Made by Thijs Aarnoudse