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!
I want to send in an email a bunch of html code that includes some stuff queried from a database in my mail function but I'm having a problem having the queries within my message variable for the mail function.
Im including the important parts of the code, but much of it is left out: (the important part is having the php echos inside the html code...so is there a way to get this done?)
That's an acceptable way to send HTML e-mail. The problem you have is that you need to enclose the HTML markup in quotes. This is how your code should look:
Thanks for your quick response. I didn't realize all I needed to do was take out the "php echo" and it would work! (oh, and add the quotes at the beginning).
But, what if in my code I have double quotes I can't change them all to single because that will invalidate some of the properties, I think.