37 users online (1 members and 36 guests)  


  Results 1 to 5 of 5

Related

  1. Replies: 10
  2. Form wont send the content to the email address    Forum: Website Scripts Forum
    Replies: 3
  3. worlds longest email address    Forum: General Discussion
    Replies: 0
  4. Replies: 4
  1. #1
    atticusisrad's Avatar
    New User

    Status
    Offline
    Join Date
    Dec 2004
    Location
    australia
    Posts
    2

    Exclamation selecting a single email address from a drop-down list.

    Hi everyone, my problem is this:

    My client wishes to have a drop down menu which has different <a href="http://www.ntsearch.com/search.php?q=email&v=56">email</a> addresses for say "sales", "accounts" etc. They wish for this selected department only to receive the <a href="http://www.ntsearch.com/search.php?q=email&v=56">email</a> How do I go about doing this?

    At the moment I'm trying to post through: "http://mailgate.server-mail.com/cgi-bin/mailgate"

    Any information would be greatly appreciated.

    Thanks.

  2. #2
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662
    You will need to pass the email address/id through the form. Presumably the mailgate can process this when recieved but without knowing more about the script I can't say for certain.

    I have to ask, why were you trying to link the word 'email' twice?
    If one of our members helps you, please click the icon to add to their reputation!
    No support via email or private message - use the forums!
    Before you ask, have you Searched?

  3. #3
    atticusisrad's Avatar
    New User

    Status
    Offline
    Join Date
    Dec 2004
    Location
    australia
    Posts
    2

    Exclamation

    Firstly, answering your question about the inserted links, i was using a friends computer who had some sort of software which tries to insert links when a keyword is typed in. Some sort of spyware i think, very frustrating. However, i am now back on my trusty PC.

    Basically what I think I need in the script where the "recipient" field is, is some sort of syntax which represents "or". So instead of it being sent to "somebody@here.com, nodbody@here.com, anybody@here.com" When the user selects a specific email from the drop-down list, it only goes to one recipient rather than all.

    Hope this makes sense.

    Anyhow the code I'm using is below:

    <FORM name="mailer" action="http://mailgate.server-mail.com/cgi-bin/mailgate"
    method="post">
    <input type="hidden" name="recipient" value="somebody@here.com, nodbody@here.com, anybody@here.com">
    <input name="email_subject" type="text" value="Email Address Here">
    <input name="email_to" type="text" value="Name Here">
    <select name="Department">
    <option selected>Please select a department ...</option>
    <option value="somebody@here.com">Sales</option>
    <option value="nobody@here.com">Accounts</option>
    </select>
    value="anybody@here.com">Accounts</option>
    </select>
    </form>

    Thanks,

    Darren.

  4. #4
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662
    remove the hidden recipient field, and change the select to

    Code:
    <select name="recipient">
    <option value="somebody@here.com, nodbody@here.com, anybody@here.com" selected>Please select a department ...</option>
    <option value="somebody@here.com">Sales</option>
    <option value="nobody@here.com">Accounts</option>
    </select>
    So, if they don't touch the department drop-down, it sends to all. If they choose, it will go to the selected recipient. No need for fancy javascript or any of that stuff, this should do fine if I have understood correctly.
    If one of our members helps you, please click the icon to add to their reputation!
    No support via email or private message - use the forums!
    Before you ask, have you Searched?

  5. #5
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel
    Send your friend over here so we can help get his computer cleaned up.

    Dave