Find all the Prime numbers with the PHP function
<?php
function find_prime_nums($start, $end){
for($i=$start; $i<=$end; $i++){
$counter = 0;
for($j=1; $j<=$i; $j++){
if($i%$j == 0){
$counter++;
}
}
if($counter == 2) {
echo "$i - is a prime number. <br/>";
}
}
}
find_prime_nums(2,10);
?>