Results 1 to 6 of 6

Thread: Suppress standard submit with ExtJS

  1. #1
    Sencha User dimebag's Avatar
    Join Date
    Aug 2009
    Posts
    53

    Default Suppress standard submit with ExtJS

    Hi folks, I have a existing app and enhanced it with ext. Now I need to suppress a standard submit of a form (non-ext). Is there a way to do this with Ext, maybe with e key-eventhandler?

    Many thanks!

  2. #2
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,890

    Default

    Listen for the event then stop it.

  3. #3
    Sencha User dimebag's Avatar
    Join Date
    Aug 2009
    Posts
    53

    Default

    I did this with no success:

    Code:
            var searchform = Ext.get('searchform');
            searchform.on('submit', function(event, html, obj) {
                 
                    event.stopPropagation();
            });

  4. #4
    Sencha User
    Join Date
    Aug 2009
    Posts
    480

    Default

    Try returning false instead.

  5. #5
    Sencha User Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,245

    Default

    event.stopEvent() is even better.

  6. #6
    Sencha User dimebag's Avatar
    Join Date
    Aug 2009
    Posts
    53

    Default

    That works, thanks my friends!

Similar Threads

  1. standard submit vs. ajax in login form
    By dolittle in forum Ext 2.x: Help & Discussion
    Replies: 8
    Last Post: 9 Mar 2009, 11:20 AM
  2. submit form as JSON, suppress other fields
    By Hugh.Lynch in forum Ext 1.x: Help & Discussion
    Replies: 9
    Last Post: 14 Oct 2008, 2:22 AM
  3. Standard Submit with File Upload
    By kouphax in forum Ext 2.x: Help & Discussion
    Replies: 6
    Last Post: 29 Jul 2008, 2:22 AM
  4. Extending Standard Submit - OOSubmit
    By surfyogi in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 21 Apr 2008, 12:57 PM

Posting Permissions

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