Module

Developer
Supported

EE 1
EE 2
Stand-Alone Member Edit

Back to this add-on's main page
View Other Add-ons From Yuri Salimovskiy

     

You must be logged in to post.

Error “The action you have requested is invalid”

Support Request

esotm
esotm

We are getting a “The action you have requested is invalid” error when we try to submit a Stand-Alone Member Edit form. Although, the data is being updated when we go back to it so it is working.

Any suggestions on how to fix or diagnose the error?

Yuri Salimovskiy
# 1
Developer
Yuri Salimovskiy

Please make sure you’re using the latest version and that you have Member module installed.

Otherwise manual debugging of submit function is necessary.

esotm
# 2
esotm

I have both the Member module installed and the latest version of SAME installed. Any other suggestions?

Yuri Salimovskiy
# 3
Developer
Yuri Salimovskiy

Please email to support@intoeetive.com the link and sample data where I can reproduce the problem. I’ll try to help.

mrtopher
# 4
mrtopher

Hey Yuri, any progress on this issue? I’m experiencing the same thing (pardon all the mark-up).

{exp:sa_member_edit:form class="form-horizontal"}
    
 {exp
:member:custom_profile_data}

     
<div class="control-group">
      <
label class="control-label" for="first_name">First Name: <em>*</em></label>
      <
div class="controls">
       <
input type="text" name="first_name" value="{first_name}" id="first_name" />
      </
div>
     </
div>

     <
div class="control-group">
      <
label class="control-label" for="last_name">Last Name: <em>*</em></label>
      <
div class="controls">
       <
input type="text" name="last_name" value="{last_name}" id="last_name" />
      </
div>
     </
div>

     <
div class="control-group">
      <
label class="control-label" for="email">E-mail: <em>*</em></label>
      <
div class="controls">
       <
input type="text" name="email" value="{email}" id="email" />
      </
div>
     </
div>
     
     <
input type="hidden" name="username" value="{email}" />

     <
div class="control-group">
      <
label class="control-label" for="email_updates">Get e-mail updates? <em>*</em></label>
      <
div class="controls">
       <
label class="radio"><input type="radio" name="email_updates" value="Yes" id="email_updates" {if email_updates == 'Yes'}checked{/if} /> Yes</label
       <
label class="radio"><input type="radio" name="email_updates" value="No" {if email_updates == 'No'}checked{/if} /> No</label>
      </
div>
     </
div>

 
{/exp:member:custom_profile_data}
     
 
<div class="control-group">&nbsp;</div>
 
    <
div class="control-group">
     <
label class="control-label" for="current_password">New Password:</label>
     <
div class="controls">
      <
input type="password" name="current_password" id="current_password" />
     </
div>
    </
div>

    <
div class="control-group">
     <
label class="control-label" for="password">Re-type Password:</label>
     <
div class="controls">
      <
input type="password" name="password" id="password" />
     </
div>
    </
div>
    
    <
div class="control-group">&nbsp;</div>

    <
div class="control-group">
     <
label class="control-label" for="password_confirm">Current Password: <em>*</em></label>
     <
div class="controls">
      <
input type="password" name="password_confirm" id="password_confirm" />
     </
div>
    </
div>      

    
    <
div class="control-group">
     <
label class="control-label">&nbsp;</label>
     <
div class="controls pull-right">
      <
label class="control-label"><em>*</emRequired fields</label>
     </
div>
    </
div>
          
 <
div class="form-actions">
  <
button type="submit" class="btn btn-primary">Save changes</button>
 </
div>

{/exp:sa_member_edit:form} 

When I submit the form I get an EE error messaging saying “The action you have requested is invalid.”

esotm
# 5
esotm

This was from Yuri via email that worked for me…

“You were submitting username, email and password without current_password field. The system thought you were trying to change those (though they were the same). Try splitting the form into two parts: one for custom fields and one for username/email/password. Changing username username/email requires current_password field and changing password requires password, conform_password and current_password fields.”

mrtopher
# 6
mrtopher

Thanks for the reply esotm! I removed email and new password from the form and I get a success message but the data is not updated in the DB.

{exp:sa_member_edit:form class="form-horizontal"}
    
 {exp
:member:custom_profile_data}

     
<div class="control-group">
      <
label class="control-label" for="first_name">First Name: <em>*</em></label>
      <
div class="controls">
       <
input type="text" name="first_name" value="{first_name}" id="first_name" />
      </
div>
     </
div>

     <
div class="control-group">
      <
label class="control-label" for="last_name">Last Name: <em>*</em></label>
      <
div class="controls">
       <
input type="text" name="last_name" value="{last_name}" id="last_name" />
      </
div>
     </
div>

     <
div class="control-group">
      <
label class="control-label" for="email_updates">Get e-mail updates? <em>*</em></label>
      <
div class="controls">
       <
label class="radio"><input type="radio" name="email_updates" value="Yes" id="email_updates" {if email_updates == 'Yes'}checked{/if} /> Yes</label
       <
label class="radio"><input type="radio" name="email_updates" value="No" {if email_updates == 'No'}checked{/if} /> No</label>
      </
div>
     </
div>

 
{/exp:member:custom_profile_data}
 
    
<div class="control-group">
     <
label class="control-label" for="password">Current Password <em>*</em></label>
     <
div class="controls">
   <
input type="password" name="password" id="password" />
     </
div>
    </
div>
     
    <
div class="control-group">
     <
label class="control-label">&nbsp;</label>
     <
div class="controls pull-right">
      <
label class="control-label"><em>*</emRequired fields</label>
     </
div>
    </
div>
          
 <
div class="form-actions">
  <
button type="submit" class="btn btn-primary">Save changes</button>
 </
div>

{/exp:sa_member_edit:form} 

The password field is in the above example but I tried it without and I get the same success message but the data is not updated.

Yuri Salimovskiy
# 7
Developer
Yuri Salimovskiy

If you update only custom fields, then the password is not required at all. Try removing this field completely.