On Wednesday 16 January 2002 03:32, Kevin Ruiz wrote: This isn't a db related question!
> I'm writing a page that allows me to add users to a table. Once the users > are in the table they will be able to gain access to our downloads section, > they will be validated against their user/pass in a mysql database. > > Here's my question. I understand how to send mail using mail(). I also > understand how to send mail in an html format which is what I'd prefer to > do but what I'm having trouble with is passing my variables to the email > being generated in the html format. This works fine in the plain text > emails but can't seem to get it to work in the html emails. > > Here's my situation...once a new user is added to the database an email is > generated with their user/pass. The code I am using to send them the email > is this: > > ================================================================ > //mails the new account holder his/her username and pass > //for testing purposes I'm sending all mail to myself > /* recipients */ > $to = "Kevin Ruiz <[EMAIL PROTECTED]>"; > > /* subject */ > $subject = "Access to downloads section at Worktiviti.com"; > > /* message */ > $message = ' You're using single quotes to define the $message string thus no variable expansion takes place. I suggest breaking up the assignment into several chunks, for example: $message = 'Hello ' . $name . ', how are you'; hth -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk /* Love is in the offing. -- The Homicidal Maniac */ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]