Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    May 2007
    Posts
    15
    Thanks
    1
    Thanked 0 Times in 0 Posts

    PHP Email : Send to Email in Recordset

    My script sends email fine when I have a hard-coded email address but when I try to dynamically change the email recipient based on the results of a recordset, the email script fails.

    Clearly, I have the wrong syntax. The code below is incomplete and shows just the relevant part of the script:

    Code:
    	<?php
            $to = $row_rs_password['email_address'];
            $subject = 'Rycote.com - Password Request';
            $from = 'root@crozius.com';
            $message ='';
    My problem, it seems, has to do with : $row_rs_password['email_address'].

    What is the proper syntax?

    Thanks very much for any feedback!

  • #2
    Super Moderator Inigoesdr's Avatar
    Join Date
    Mar 2007
    Location
    Florida, USA
    Posts
    3,642
    Thanks
    2
    Thanked 405 Times in 397 Posts
    You're going to have to show more code... specifically the recordset.

  • #3
    New Coder
    Join Date
    May 2007
    Posts
    15
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Thanks for the reply! Turns out my recordset and syntax are fine. There was a problem with the mail server and I didn't receive the email until some hours later.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •