Submit Button

For general questions and discussions specific to the AbleCommerce GOLD ASP.Net shopping cart software.
Post Reply
ZPCAC
Lieutenant, Jr. Grade (LT JG)
Lieutenant, Jr. Grade (LT JG)
Posts: 40
Joined: Wed Apr 16, 2014 11:08 am

Submit Button

Post by ZPCAC » Mon Nov 02, 2015 7:20 am

Hello -

I am working through some udates on our webstore and i would like to have a button that once is clicked submits the information and close the webpage. Below is the current code for the button.

<asp:Button ID="Submit" runat="server" Text="Submit Tab Titles/Colors" OnClick="close" ValidationGroup="ContactUs" />
&nbsp;&nbsp;&nbsp;<asp:Button ID="reset" OnClientClick="document.location.href=document.location.href;" Text="Reset" runat="server" />

Any help would be appreciated !

Bret

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: Submit Button

Post by mazhar » Mon Nov 02, 2015 7:54 am

Where do you want to submit the information when Submit button is hit? In ASP.NET you have to write some server code to handle the button click and then redirect user to some different page.

ZPCAC
Lieutenant, Jr. Grade (LT JG)
Lieutenant, Jr. Grade (LT JG)
Posts: 40
Joined: Wed Apr 16, 2014 11:08 am

Re: Submit Button

Post by ZPCAC » Mon Nov 02, 2015 8:00 am

mazhar wrote:Where do you want to submit the information when Submit button is hit? In ASP.NET you have to write some server code to handle the button click and then redirect user to some different page.
below is the code that links to our root directory

[[ConLib:custom/CustomIndexing3 SendTo="customerservice@zackproducts.com" EnableCaptcha="false" Subject="Custom Indexing Order"]]

The Send to : customerservice@zackproducts.com is where the form is submitted

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: Submit Button

Post by mazhar » Mon Nov 02, 2015 8:09 am

Look for the code file. For example there could be CustomIndexing3.ascx.cs file containing the code to handle button click. If you are using AbleCommerce contactus control then look for following function.

Code: Select all

protected void Submit_Click(object sender, EventArgs e)
        {
            
        }
Put redirect code just above the close curly brance } like

Code: Select all

protected void Submit_Click(object sender, EventArgs e)
        {


            Response.Redirect("Default.aspx");
        }

Post Reply