SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Addict itHighway's Avatar
    Join Date
    Jan 2008
    Location
    GUJ
    Posts
    270
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Submit button issue... two forms...

    Please see the attached image below. When I click the submit button on top it invoke the validation part. How should I fix it so that when I click "Search Submit" button it submit the form to next page.

    Attached Images Attached Images

  2. #2
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,649
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    From a HTML sense there is only one form on the page, any postback will trigger validation. Two ways to handle this:

    a) move that search form outside of the server-enabled ASP.NET form and perhaps use GET -- really better semantically and lets you have linkable search results pages.
    b) Look into the ValidationGroup property on your forms / validators. You could also disable validation for that form in the top right.

  3. #3
    SitePoint Enthusiast
    Join Date
    Jun 2007
    Location
    Marysville, CA
    Posts
    59
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

  4. #4
    SitePoint Member
    Join Date
    Jul 2013
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Direct commands are available in ASP.NET, you an use them.

  5. #5
    Chopped Liver bronze trophy imaginekitty's Avatar
    Join Date
    Aug 2007
    Location
    Pennsyltucky
    Posts
    1,494
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    I'm a bit rusty but does wrapping the forms in their own <asp:Panel> and using the Panel's DefaultButton attribute help?


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
  •