Looks good for a first script. My first script was trying to connect to a database - at the time I thought I would never get it, and here it is 6 years later - I LOVE PHP!!
OK, I digress...
Something you need to know about security -
- NEVER trust input from the user!
This means if the user has input some value and that value becomes a part of your script - do not trust it. Eventhough you do not have a call to any database functions here, I am going to use it as an example...
<input type = 'text' name = 'testelement' size = '10'>
The user can then enter something sinister using a single quote, and injecting their own code in the select or insert statement and wreak havoc on your server.
This is called an SQL injection attack.
How does this apply to your script?
Well, you are trusting your users input. They may not be up to something sinister, but what if they make a mistake when entering their email address? The email will be sent, but to the wrong person! The user would then think that they have sent an email successfully, but in reality, they did not.
How to remedy the situation....
Use regular expressions to catch mistakes and to validate your users input. This does two things - it ensures that they are inputing the information in the correct format, and the user is not putting something you don't want in there.
Regular expressions are mystic little creatures, but with some taming and a whip, you will be using them alot - and enjoying it! I suggest doing a google search on "PHP regular expressions validating email". There is a regular expression out there that will check to see if the email is in the format abc@abc.abc. Regular expressions seem to be difficult at first, but they are not really. All a regular expression is is a function that matches a pattern in a given string.
Hope all that helps man.
For the most part, though - the script looks good.