I have tried a few different ways to get two email address to send on a case statement. How do I add to commands on same line? I am just a little off track. Thanks for your help.

case 'it':
$to_email = "erich.krauz@rgl-e.com"; $to_email = "krauz2@hotmail.com";

break;

I have tried a few different ways to get two email address to send on a case statement. How do I add to commands on same line? I am just a little off track. Thanks for your help.

case 'it':
$to_email = "erich.krauz@rgl-e.com"; $to_email = "krauz2@hotmail.com";

break;

Could you expand on this. This is two commands on the same line but because you are using the same variable, the first command is pointless. What are you trying to do?

i have a switch going on and when it clicked on "IT" it needs to send the information to two email address. I got it so it sends to one but i cant get it to send to two. I am new to php but in c++ I think you did one of these numbers...> to add on same line. Does this help?

i have a switch going on and when it clicked on "IT" it needs to send the information to two email address. I got it so it sends to one but i cant get it to send to two. I am new to php but in c++ I think you did one of these numbers...> to add on same line. Does this help?

Are you trying to concatenate the strings?
$to_email = "erich.krauz@rgl-e.com" . ", krauz2@hotmail.com";

this would be
$to_email = "erich.krauz@rgl-e.com, krauz2@hotmail.com";

Yes, Thank you!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.