<?php $pin1='1234'; $pin2='1234-5678'; $pin3='1234-5678-0000-5566-8900-5600-4555-1330-2334'; function countPin($pin) { return substr_count($pin, '-') + 1; } echo 'Pin 1 heeft ' . countPin($pin1) . ' code(s), '; echo 'pin 2 heeft ' . countPin($pin2) . ' code(s) en '; echo 'pin 3 heeft ' . countPin($pin3) . ' code(s).';
You have javascript disabled. You will not be able to edit any code.