Birthday dropdown

Hmmm, I’ve been looking all over for this code that I guess is used a lot.
I have a from where user will register and I want them to fill in their birthday using three dropdowns.

The first one, called year, I would like to be from this year and then back 100 years.
The next one called month and the last one day.

I guess it would be easy to find this code online, but since I’m not used to the language (I’m from Sweden). I just don’t know what to look for and what it’s called. Haven’t found it yet.

So, if anyone have a link or just a code that I can use for this simple thing (I guess it’s pretty simple), but I just can’t figure out how to do it.

<?php
	echo '<select name="year">';
	  echo '<option></option>';
		for($i = date('Y'); $i >= date('Y', strtotime('-100 years')); $i--){
		  echo "<option value='$i'>$i</option>";
		} 
	echo '</select>/';
	echo '<select name="month">';
		echo '<option></option>';
		for($i = 1; $i <= 12; $i++){
		  $i = str_pad($i, 2, 0, STR_PAD_LEFT);
			echo "<option value='$i'>$i</option>";
		}
	echo '</select>/';
	echo '<select name="day">';
	  echo '<option></option>';
		for($i = 1; $i <= 31; $i++){
		  $i = str_pad($i, 2, 0, STR_PAD_LEFT);
			echo "<option value='$i'>$i</option>";
		}
	echo '</select>';
?>

Thanks a lot. That is just what I was looking for. Now I can continue with the rest of the form and functions.

Thank you.