Jump to content

'Save' option disabled=disabled despite passing verification/checks


SVCode

Recommended Posts

Hi there,

 

I'm working on a really simple theme, based on Six but with more or less everything stripped out - this is basically a migration of our theme that ran on 'five' to 'six' so that the updated carts can be suppported. The menu bar is replaced with a custom menu list on the right-hand side, nothing fancy.

 

From the account/product details page, I'd like to have the change password option on the main product detail page (i.e clientarea.php?action=productdetails&id=2xx). So, I added the below and removed the tabs.

 

Whilst I can fill in both password boxes, and they're confirmed as matching by the UI feedback, the 'Save' button still remains disabled. If I use something like Chrome Developer mode to remove 'disabled=disabled from the 'Save' button, I can change the password and all is well - the password is changed correctly.

 

I'm assuming the jQuery aspect is fine, as the button is disabled to start with, it just doesn't enable when both passwords are entered and match - so perhaps I've broken the CSS somewhere, so it doesn't match/update? Can someone point me in the direction of what to check? The form itself is a copy and paste from the actual file, it has the correct 'form-group' all the way through. But clearly I'm missing something...

 

Cheers,

 

<div class="tab-pane" id="tabChangepw">
       <h2>Change Account Password</h2>
<br /><br />
       {if $modulechangepwresult}
           {if $modulechangepwresult == "success"}
               {include file="$template/includes/alert.tpl" type="success" msg=$modulechangepasswordmessage textcenter=true}
           {elseif $modulechangepwresult == "error"}
               {include file="$template/includes/alert.tpl" type="error" msg=$modulechangepasswordmessage|strip_tags textcenter=true}
           {/if}
       {/if}

       <form class="form-horizontal using-password-strength" method="post" action="{$smarty.server.PHP_SELF}?action=productdetails" role="form">
           <input type="hidden" name="id" value="{$id}" />
           <input type="hidden" name="modulechangepassword" value="true" />

           <div id="newPassword1" class="form-group has-feedback">
               <label for="inputNewPassword1" class="col-sm-5 control-label">New Account Password</label>
               <div class="col-sm-6">
                   <input type="password" class="form-control" id="inputNewPassword1" name="newpw" autocomplete="off" />
                   <span class="form-control-feedback glyphicon"></span>
                   {include file="$template/includes/pwstrength.tpl"}
               </div>
           </div>
           <div id="newPassword2" class="form-group has-feedback">
               <label for="inputNewPassword2" class="col-sm-5 control-label">Confirm new Account Password</label>
               <div class="col-sm-6">
                   <input type="password" class="form-control" id="inputNewPassword2" name="confirmpw" autocomplete="off" />
                   <span class="form-control-feedback glyphicon"></span>
           <div id="inputNewPassword2Msg">
                   </div>
               </div>
           </div>
           <div class="form-group">
               <div class="col-sm-offset-6 col-sm-6">
                   <input class="btn btn-warning" type="submit" value="{$LANG.clientareasavechanges}" />
                   <input class="btn" type="reset" value="{$LANG.cancel}" />
               </div>
           </div>

       </form>
   </div>

 

EDIT: The header.tpl has all the usual includes, head.tpl is the default for the 'six' theme. Does it load something else from one of the menu's I've removed perhaps?

Edited by SVCode
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated