Results 1 to 7 of 7

Thread: Form/Submit Button.

  1. #1
    Silent Emotion Rainecloud's Avatar
    Join Date
    Sep 2000
    Location
    England
    Posts
    5,345
    Articles
    70
    Contributions
    • Former Site Staff

    Default Form/Submit Button.

    I'm currently updating a website for my boss at work, but there's one part I can't seem to get right. He has a 'submit' button underneath a 'form' which is supposed to send the filled out form to his e-mail address. Now, I can't find any sort of code on the page that I can alter to customize the button.

    Basically, I want to be able to put a button on the page that submits a completed form (which I've done correctly) to a certain e-mail address. Any ideas as of how to go about this?

    Thanks in advance, and I hope I'm making sense.
    "As the days go by, we face the increasing inevitability that we are alone in a godless,
    uninhabited, hostile and meaningless universe. Still, you've got to laugh, haven't you?"

  2. #2
    Old school, like an old fool. Flying Mullet's Avatar
    Join Date
    Apr 2003
    Location
    Napping in a peach tree.
    Posts
    19,185
    Articles
    6
    Blog Entries
    7
    Contributions
    • Former Administrator
    • Former Cid's Knight
    • Former Senior Site Staff

    Default

    I'm assuming that you have a submit button on the page, like so:
    <input type="submit" yada yada>

    If that's the case, you can use a style sheet to manipulate the look of the button like so(in a style-sheet or an in-house style attribute):
    submit.Raincloud {background-color: #FAFAFA;
    font-size: 11;
    font-family: verdana, arial, courier, sans-serif;
    color: #141414}
    where the class of the submit button is "Raincloud".

    And if it's just a standard button that has a javascript onclick() that does the submitting, you have a button like this:
    <input type="button" value="Submit" yada yada onclick="xxxx">

    and you set up your style like so:
    button.Raincloud {background-color: #FAFAFA;
    font-size: 11;
    font-family: verdana, arial, courier, sans-serif;
    color: #141414}
    and again set the class of the button to "Raincloud"

    Hope this helps.
    Figaro Castle

  3. #3
    Silent Emotion Rainecloud's Avatar
    Join Date
    Sep 2000
    Location
    England
    Posts
    5,345
    Articles
    70
    Contributions
    • Former Site Staff

    Default

    But there isn't any code to tell the button to send the completed form in an e-mail to my boss' account.

    Normally I'm alright with this design stuff, but I hate buttons...
    "As the days go by, we face the increasing inevitability that we are alone in a godless,
    uninhabited, hostile and meaningless universe. Still, you've got to laugh, haven't you?"

  4. #4
    Super-Rad Recognized Member Spatvark's Avatar
    Join Date
    Oct 2001
    Location
    The Mysterious Island of Bigfoot Women
    Posts
    2,098
    Articles
    7
    Contributions
    • Former Cid's Knight
    • Former Senior Site Staff

    Default

    Chuck up teh code you have (attached in a html file that is) and I should be able to work it out. I don't have much experience with this kinda thing in html, but I learn quickly =P
    Seriously the best band in the world.
    And here's where I'll stay / For ten years and a day
    We're on a quest to find hidden treasure / And mystery on The Wild Sea

  5. #5
    ORANGE Dr Unne's Avatar
    Join Date
    Dec 1999
    Posts
    7,394
    Articles
    1
    Contributions
    • Former Administrator
    • Former Developer
    • Former Tech Admin

    Default

    In HTML, all a form does is take user input in the form of textboxes, textareas, radio buttons, dropdown menus or whatever, and transforms it into either GET or POST data, and sends that data somewhere (specified in the FORM tag by <b>action="uri_of_a_script"</b>). The script itself has to then parse the GET or POST data, and then that script can do whatever it wants with it, for example sending it somewhere via email, saving it to a file or database, generating and displaying a new HTML document using that data in some way, etc. So you need a script (Perl, Javascript maybe, whatever) in addition to an HTML document.

  6. #6

    Default

    <A HREF="http://www.scriptarchive.com/formmail.html">Form Mail</A> is probably the script you need. It's the one I've set up on my website, and it seems to work well. I had the same problem as you, Raine, in that I couldn't find an e-mail submit script, and Form Mail is what I settled on. It's certainly popular, although whether that's a good thing or not is open to question.

    I think e-mailing forms used to be allowed, but there were huge problems with them. I'm pretty sure it was eliminated from HTML a long time ago.

  7. #7
    Silent Emotion Rainecloud's Avatar
    Join Date
    Sep 2000
    Location
    England
    Posts
    5,345
    Articles
    70
    Contributions
    • Former Site Staff

    Default

    In HTML, all a form does is take user input in the form of textboxes, textareas, radio buttons, dropdown menus or whatever, and transforms it into either GET or POST data, and sends that data somewhere (specified in the FORM tag by action="uri_of_a_script").
    Unne, you're a saviour.

    Thanks to everyone else for your assistance, too.
    "As the days go by, we face the increasing inevitability that we are alone in a godless,
    uninhabited, hostile and meaningless universe. Still, you've got to laugh, haven't you?"

Posting Permissions

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