Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    24
    Vote Rating
    0
    developerankit is on a distinguished road

      0  

    Default Having problem with form.submit method

    Having problem with form.submit method


    Hello All,

    I am getting a very critical problem in 'Submit' method, when I register a new user first time it save the user correct details. But then again I try to register one more user, its post the previous cached details in form data and I got the 'user already exists error message'.

    Please give me any solutions to clear its cached data or refresh form data all times, when form is submitted.

    My code is below:

    registration.submit({
    url: 'services/index.php/user/userRegister/',
    method: 'POST',
    success: function(result, response) {
    if(response.msg == 'ALREADY_EXISTS') {
    //if user with same email id already exists
    Ext.Msg.alert('Validation Error', 'This user already exists');
    } else if(response.msg == 'SUCCESS') {
    //if new user register successfully, then make it loggedin
    sessionStorage.setItem("email", response.email);
    sessionStorage.setItem("display_name", response.display_name);
    sessionStorage.setItem("firstname", response.firstname);
    sessionStorage.setItem("lastname", response.lastname);
    window.location = '#addgolfbag';
    } else if(response.msg == 'ERROR') {
    //if there is any server error while registration
    Ext.Msg.alert('Error while registration');
    }
    },
    failure: function(result, response) {
    Ext.Msg.alert(response);
    }
    });

    Please help me !!!!!!!!!!

    Thanks
    Ankit Aggarwal

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,519
    Vote Rating
    814
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    use sessionStorage.removeItem to remove an item
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    24
    Vote Rating
    0
    developerankit is on a distinguished road

      0  

    Default not fixed

    not fixed


    Hello,

    My problem is not with sessionstorage, I just want to know, is sessionstorage responsible for cached 'form data' sent by submit method all time untill, I don't make hard refresh (ctrl + f5) page.

    In sessionstorage I am justing saving few details, but submit method post all fields with previous data (which sent on first time). So I think its 'Submit' method problem.

    I am having the same problem with login form as well....

    In fact I have tested with sessionStorage.removeItem as well, But still facing the same problem. Its submit the previous data...

    Please help me ASAP !!!!!!!

    Thanks
    Ankit Aggarwal

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,519
    Vote Rating
    814
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Set a breakpoint and follow the code. It should iterate through all fields and get it's value just fine.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  5. #5
    Sencha User
    Join Date
    Apr 2012
    Posts
    24
    Vote Rating
    0
    developerankit is on a distinguished road

      0  

    Default not fixed

    not fixed


    Hello

    Thanks for supporting me, but the actual problem is that 'getValues()' method returning the cached values.

    Please consider these steps:

    1. I did submit the login form with correct details, it moves to 'home' page with logged in. ---- correct
    2. I did logout from there and it moves back to login form and destroy all sessions. ---- correct
    3. But now even if I did not enter any details and press login button, its goes redirect. Because its getting the previous cached username and password. Its incorrect and that is my problem. ---- in correct

    Please help me to fix it out....

    Thanks
    Ankit Aggarwal

Thread Participants: 1