generate functionThu, 15 Dec 2022

generate random dark hex color

<?php $hex = array('0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'); $color = '#'; for($i=1;$i<=6;$i++){ $color .= $hex[rand(0,15)]; } echo $color; ?>

Questions about programming?Chat with your personal AI assistant