PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
tags where appropriate when posting code. Read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url][/color]
hi can anyone help me with my php email form, it is to change the email address when selected from a dropdown menu
to view what i have been testing go onto http://www.jarcodesigns.co.uk/contactform.php
currently i have this code
tags where appropriate when posting code. Read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url][/color]
i declare the $department variable here and im going to validate it when iv sorted out this problem
I can't tell that you have said what the problem is? As hawleyjr says, you are testing $department with if's before it is declared. And your if checks are for $department[$key] == 1, but you haven't declared $department or $key that we can tell. Plus, shouldn't that be $department[1] == 'Web Design (Ryan Norton)' or something.
Looking at your actual form online you now have single quotes around the form option labels.