Page 2 of 6 FirstFirst 1234 ... LastLast
Results 11 to 20 of 52

Thread: TO and CC plus multiple option values.

  1. #11
    Join Date
    Feb 2013
    Posts
    37

    Default Re: TO and CC plus multiple option values.

    So this should be good now?

    <label>Select which department you would like to contact.</label></td>
    <td valign="top"><select name="recipients" id="recipients" class="select valid">
    <option value="">Select One</option>
    <option value="Public Works">Public Works</option>
    <option value="Construction Office">Construction Office</option>
    <option value="Economic Development">Economic Development</option>
    <option value="Police & Fire">Police & Fire</option>
    <option value="Administration & Other">Administration & Other</option>
    <option value="Website Issues">Website Issues</option>
    </select>

    and this?

    <form action="/cgi-bin/formmail.php" method="POST">
    <input type="hidden" name="derive_fields" value="Department=recipients">

    If this is all good now then back to the formmail.php file for a bit. The
    $TARGET_EMAIL = array(EMAIL_NAME."@yourhost\.com$");

    Do I need to put all the email address's here, that would mean all 12, the TO's and the CC's.

    You also mentioned the ampersand. Where should that be changed to "and"?





    Quote Originally Posted by ginger23 View Post
    You have two <select> tags and should only have the one with the name "recipients". Then you can create a label that would tell the user to select a department.

    HTML Code:
    Please select the department you'd like to contact: <select class="select valid" name="recipients" id="recipients">
    You'd probably want to use derive_fields then if you need to display the department name in your email results.

    HTML Code:
    <input type="hidden" name="derive_fields" value="Department=recipients">
    (Hopefully that will give you the department name value in the recipients field and not the email address.)

    Then in the php script you'll need to set the value of "$FORM_INI_FILE" which is a server path to where the ini file is located on the server. (Preferably it should be stored above the root so it's not accessible to the public.) You can get the server path to the script by running testalert. Put this in your browser: http://yourdomain.com/path-to-formmail.php?testalert=1 . You should then receive an email with the server path which you can adjust according to where you've placed your INI file. (This email will go to the email address you specified in the $DEF_ALERT setting in formmail.php).



    Code:
    $FORM_INI_FILE = "/path/to/formmail.ini";
    ginger

  2. #12
    Join Date
    May 2008
    Posts
    1,291

    Default Re: TO and CC plus multiple option values.

    You might be missing some of my posts. In the lists of posts in this thread (hybrid view) there may be other posts that I made that might not be in the right order because I was responding to an earlier post after I had responded to the last post.

    Anyway, the ampersands should probably be changed in the ini file as well as <option value="Blank and Blank">

    Again, I responded to your question about email addresses needing to be in $TARGET_EMAIL. Try look back through and see if you can find a couple of other posts I made that might not be in order by time posted.

    ginger

  3. #13
    Join Date
    May 2008
    Posts
    1,291

    Default Re: TO and CC plus multiple option values.

    ... and if all else fails check your email because I think the notification email contains the contents of the post as well.

    ginger

  4. #14
    Join Date
    Feb 2013
    Posts
    37

    Default Re: TO and CC plus multiple option values.

    1. Not sure what you mean by the ampersands in the ini file, this is what is in it now.
    [email_addresses]
    Public Works = "the TO email address,the CC email address"
    Construction = "the TO email address,the CC email address"
    Economic Development ="the TO email address,the CC email address"
    Police Fire = "the TO email address,the CC email address"
    Administration Other = "the TO email address,the CC email address"
    Website Issues = "the TO email address,the CC email address"

    2. Is this correct?
    <form action="/cgi-bin/formmail.php" method="POST">
    <input type="hidden" name="derive_fields" value="Department=recipients">

    3. Is all this correct?
    <label>Select which department you would like to contact.</label></td>
    <td valign="top"><select name="recipients" id="recipients" class="select valid" name="Select which dept. you would like to contact." id="Select which dept. you would like to contact.">
    <option value="">Select One</option>
    <option value="Public Works">Public Works</option>
    <option value="Construction Office">Construction Office</option>
    <option value="Economic Development">Economic Development</option>
    <option value="Police & Fire">Police & Fire</option>
    <option value="Administration & Other">Administration & Other</option>
    <option value="Website Issues">Website Issues</option>
    </select>

    4. Do I add all 12 email address's to this?
    $TARGET_EMAIL = array(EMAIL_NAME."@yourhost\.com$");

    5. Is that it?







    Quote Originally Posted by ginger23 View Post
    You might be missing some of my posts. In the lists of posts in this thread (hybrid view) there may be other posts that I made that might not be in the right order because I was responding to an earlier post after I had responded to the last post.

    Anyway, the ampersands should probably be changed in the ini file as well as <option value="Blank and Blank">

    Again, I responded to your question about email addresses needing to be in $TARGET_EMAIL. Try look back through and see if you can find a couple of other posts I made that might not be in order by time posted.

    ginger

  5. #15
    Join Date
    May 2008
    Posts
    1,291

    Default Re: TO and CC plus multiple option values.

    I've answered all of these questions. Are you not seeing all of my posts? Please read my responses in the email notifications you should have received notifying you of responses to your posts in this thread. If you're not receiving notifications then you probably need to update your profile to specify that you receive notifications. (There should be 8 posts by me... counting this one.)

    ginger
    Last edited by ginger23; 16-Feb-2013 at 06:03 PM.

  6. #16
    Join Date
    May 2008
    Posts
    1,291

    Default Re: TO and CC plus multiple option values.

    See this post:

    http://www.tectite.com/vbforums/show...4094#post24094

    ... and this one:

    http://www.tectite.com/vbforums/showthread.php?6287-TO-and-CC-plus-multiple-option-values.&p=24096#post24096


    A
    s for the ampersands not being in the INI file then that's correct, but the "values" in the option tags need to match what's in the INI file.
    Last edited by ginger23; 16-Feb-2013 at 06:11 PM.

  7. #17
    Join Date
    May 2008
    Posts
    1,291

    Default Re: TO and CC plus multiple option values.

    Make sure that you're viewing the forum in "Linear Mode". On the far right above the first post on this page there should be a dropdown menu that says "Display". Make sure that "linear mode" is selected.

  8. #18
    Join Date
    Feb 2013
    Posts
    37

    Red face Re: TO and CC plus multiple option values.

    I'll see if I can find your answers. Otherwise thank you so so much for all the help, its very much appreciated.


    Quote Originally Posted by ginger23 View Post
    Make sure that you're viewing the forum in "Linear Mode". On the far right above the first post on this page there should be a dropdown menu that says "Display". Make sure that "linear mode" is selected.

  9. #19
    Join Date
    May 2008
    Posts
    1,291

    Default Re: TO and CC plus multiple option values.

    I'll be around for a little while if you have questions. It would probably be a good idea if (in linear mode) you went back and read each post again. If there's something you don't understand just ask a specific question at a time.

  10. #20
    Join Date
    Feb 2013
    Posts
    37

    Default Re: TO and CC plus multiple option values.

    I just switched it to Linear and that helps. Thanks again. I need to run out for a bit. When I get back I'll make the changes and upload to the server and see if it all works. Here's a link to the page so you can actually see what we've been doing this for -

    http://www.woodbury.nj.us/contact/

    Its still working under the old way as you'll see if you view source but I'll update it all when I get back.




    Quote Originally Posted by ginger23 View Post
    I'll be around for a little while if you have questions. It would probably be a good idea if (in linear mode) you went back and read each post again. If there's something you don't understand just ask a specific question at a time.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How do I pass multiple checkbox values?
    By alinsmeier in forum Community Support
    Replies: 4
    Last Post: 22-Feb-2013, 03:43 PM
  2. How to Use the file_names option
    By Frank in forum Community Support
    Replies: 5
    Last Post: 20-Oct-2010, 10:46 PM
  3. Multiple emails in autoresponse from field values?
    By rodev in forum Community Support
    Replies: 5
    Last Post: 30-Aug-2006, 12:19 AM
  4. multiple selection for option group?
    By sutra in forum FormMail Subscription Support
    Replies: 2
    Last Post: 27-Aug-2005, 08:35 AM
  5. Exclude Option
    By zeuseason in forum FormMail Subscription Support
    Replies: 2
    Last Post: 16-Sep-2004, 08:32 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
  •