locked
Web Form HELP...PLEASE RRS feed

  • Question

  • User1906926814 posted

    Hello everyone!

    I have an unresolved issue that is haunting me and I am in serious doo doo cause my site is not functioning!!!!  The problem that is haunting me is an asp form-mailer.  I've used MS Visual Web 2005 to build a very simple site, and I mean simple (3 pages, with a customer request submission form).  My hosting company uses a specific form-mailer to capture and send email from the server.  Where I need help is that I don't understand, nor know how to finish my request submission form so it will link to their's to process the email.  Their instructions are very vauge and they don't offer code help!  They tell me in order to use the asp form-mailer, to create a web form in HTML that links to their asp script, then upload to my hosting account.  Sound easy right?  I guess if you are familiar with building sites and writing code.  However, I have no clue! I am amazed that what I currently have is working correctly (first attemp at writing/developing a site)!  I have no idea what they mean by creating a web form that links to their script.  Does this mean create an another page that somehow redirects to their script.  Does it mean adding another form to the page with my request submission form?  Where would "form" go, and how would it look in code?  Why in HTML and not through the wizzard control in VW 2005? How do you get my current submittion form on the "click" event to go to this newly created form that will then link to their script?  I am so confused that I am ready to trash the site and say the *@#& with it.  I guess that is what I get for using such a CHEAP hosting site!  So if anyone out there can HELP ME, you will not only make my day, but just about everything else.  Thanks so much in advance for your time and efforts.

     Sincerely confused,

     Darin

    Monday, April 23, 2007 10:24 AM

Answers

  • User139975600 posted

    ok. thanks this is pretty easy.  the submit button wont have a click event... it will only Submit the post... I think there is a property in your button called "UseSubmitBehavior"... ensure that is set to True.

    The example above is pretty much standard HTML.  You can use .NET server controls like hiddeninputs and textboxes.  Ensure their ID's are the same the NAME in of the inputs in the examples provided to you : name="subject"

    The form tag you will use will have the ACTION set to the ACTION on the form tag they provided to you : action="gdform.asp", though I think you will want to put the full URL to the page they want you submitting to...

    <form id="form1" runat="server" action="http://theirurl.com/gdform.asp">

    <asp:HiddenField ID="subject" runat="server" Value="Form Submission" />

    <asp:TextBox ID="FirstName" runat="server"></asp:TextBox>

     

    Hope this helps

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, April 25, 2007 7:32 AM

All replies

  • User139975600 posted

    it depends on how their script operates.  if it expects to accept parameters (values) like this...

    SendMail(ToAddress, FromAddress, Subject, Body, Importance)

    Then you could gather the form values in your page and pass them to the method like this...

    SendMail(txtTo.Text, txtFrom.Text, strTheSubject, strBuilderBody.ToString(), "High");

    if the "script" they have is a webpage or something that gathers the values from a form by itself, you may just need to POST your form to their form using the same NAME properties in your form as they use in their form.

    You will have to give more details for use to be of any more assitance.

    Tuesday, April 24, 2007 10:03 AM
  • User1906926814 posted

    Thanks.  Here are the directions I've got from the hosting company:

    To use the ASP form-mailer, create a Web form in HTML that links to our ASP script and upload it to your hosting account.

    1. Create your web form as normal and assign unique name to your form items.

        NOTE:  Keep in mind that our form-mailer script will sort the names of your form items alphabetically when it composes the email message. This is the order of precedence: uppcase letters, lowercase letters, numbers.

    3. For the form action line, enter gdform.asp. For example:

        <form action="gdform.asp" method="post">

    4. Set the form method to "post."

    5. In addition to the fields you create in your form, there are three special fields that you can use: subject, redirect and email.

        Subject. Controls the subject line in the form mail.

        Redirect. Controls the page that your visitors will see after they submit the form.

        Email. Controls the return address for the form email.

        For example:

        <form action="gdform.asp" method="post">

        <input type="hidden" name="subject" value="Form Submission" />

        <input type="hidden" name="rediret" value="thankyou.html" />

        <p>First Name:<input type="text" name="FirstName" /></p>

        <p>Last Name:<input type="text" name="LastName" /></p>

        <p>E-Mail:<input type="text" name="email" /></p>

        <p>Comments:<textarea name="comments" cols="40" rows="10">

        Type comments here.</textarea></p>

        <input type="submit" name="submit" value="submit"/>

        </form>

    6. Save and upload your file to your hosting account.

    I've tried various lines of this and have had no luck.  Like a mention earlier, I have really no experience with writing code or understanding of the differences between different codes.  I can cut and paste like a fiend though.....lol.  Does this scipt from above go into my wizard form or do I need to create a new one.  If a new one, does it mean on the same page or on a different page.  How does the one form link to the other form on the clickevent?  You think they would make this easy, but I am at a complete loss.  If you want to see their directions on their help site, click this link.  Thanks for your help!

    http://help.godaddy.com/article.php?article_id=512

     

    Thanks again,

     Darin

    Wednesday, April 25, 2007 12:05 AM
  • User139975600 posted

    ok. thanks this is pretty easy.  the submit button wont have a click event... it will only Submit the post... I think there is a property in your button called "UseSubmitBehavior"... ensure that is set to True.

    The example above is pretty much standard HTML.  You can use .NET server controls like hiddeninputs and textboxes.  Ensure their ID's are the same the NAME in of the inputs in the examples provided to you : name="subject"

    The form tag you will use will have the ACTION set to the ACTION on the form tag they provided to you : action="gdform.asp", though I think you will want to put the full URL to the page they want you submitting to...

    <form id="form1" runat="server" action="http://theirurl.com/gdform.asp">

    <asp:HiddenField ID="subject" runat="server" Value="Form Submission" />

    <asp:TextBox ID="FirstName" runat="server"></asp:TextBox>

     

    Hope this helps

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, April 25, 2007 7:32 AM