Results 1 to 4 of 4

Thread: dynamic target email

  1. #1
    Join Date
    Jun 2010
    Posts
    10

    Default dynamic target email

    Is it possible to accomplish this? http://www.tectite.com/vbforums/show...c-target-email

    Thank you.

  2. #2
    Join Date
    Dec 2003
    Posts
    3,980

    Default Re: dynamic target email

    Hi,

    Yes, what you're trying to do is fine.

    So, there must be an error or two in the code.

    First, the correct HOOK file name for this is "formmail-postconfig.inc.php".

    This ensures you're changing TARGET_EMAIL after the configuration section.

    The second concern would be the return of fetchAll. Does it return an array of rows, or a single row?

    If a single row, then you need "$the_email['email']" instead.

    To check everything, add this code to the end of the hook file:
    PHP Code:
    echo '<pre>';
    echo 
    var_dump($the_email,true);
    echo 
    var_dump($TARGET_EMAIL,true);
    echo 
    '</pre>';
    exit; 
    Russell Robinson - Author of Tectite FormMail and FormMailDecoder
    http://www.tectite.com/

  3. #3
    Join Date
    Jun 2010
    Posts
    10

    Default Re: dynamic target email

    Thanks Russell. I knew all it was going to take was the correct hook file. Renamed the hook file with my code to the one you suggested and it worked. A list of hook files and when they are called would have helped and avoided the subscription cost. Do you have a list somewhere in the docs? Thanks again.

  4. #4
    Join Date
    Dec 2003
    Posts
    3,980

    Default Re: dynamic target email

    Hi,

    No, we haven't documented the hook system because it's really designed for PHP programmers to use, and they can easily examine the code to find out what they want to use.
    Russell Robinson - Author of Tectite FormMail and FormMailDecoder
    http://www.tectite.com/

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. dynamic target email
    By spiderling in forum Community Support
    Replies: 1
    Last Post: 08-Aug-2012, 06:22 PM
  2. target email condition
    By spiderling in forum Community Support
    Replies: 4
    Last Post: 08-Mar-2011, 03:14 AM
  3. Target Email and Advanced Error Handling
    By PoorSiteCreator in forum Community Support
    Replies: 3
    Last Post: 07-May-2009, 02:58 AM
  4. target email config ?
    By ScottR in forum Community Support
    Replies: 2
    Last Post: 15-Feb-2006, 09:15 PM
  5. dynamic php generated html email not working
    By scrypton in forum FormMail Subscription Support
    Replies: 6
    Last Post: 03-Dec-2005, 11:11 PM

Bookmarks

Posting Permissions

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