Subscribe: RSS
  • Revo 2.6.2
    ClassExtender 2.1.0
    Login 1.9.5

    I'm using several extended fields with UpdateProfile,
    [[!UpdateProfile?
    	&validate=`fullName:required,lastName:required,member:required,email:required:email`
    	&excludeExtended=`email:required:email,login-updprof-btn`
    	&useExtended=`1`
    ]]

    I also ran Extend modUser so all the extended fields are represented in the Manager User Profile page. So far so good.

    Updating the profile from the front-end seems to be working fine (so far) with all the extended fields. Everything gets written/updated to the db and Manager page. The two exceptions are the default "website" and "username" fields.

    I added the "website" and "username" fields to the profile form,
    <label for="username">Username [[+error.username]]</label>
    <input type="text" name="username" id="username" value="[[+username]]">
    
    <label for="website">Website [[+error.website]]</label>
    <input type="text" name="website" id="website" value="[[+website]]">

    with the placeholders:
    Username: [[+username]]
    
    Website: [[+website]]

    The problem is both fields revert back to their previous value on save.

    Because these are default user fields (i.e. not extended) I assumed it didn't need to be included in Extend modUser.
      Todd
    • I'm not sure what's happening, but it may be because the fields already exist (i.e., they're not custom fields) and belong to different objects. username is a field of the modUser object, website is a field of the modUserProfile object. You may need to modify the code to send them to the correct locations. ClassExtender may be writing them to the extended field, which would leave the original fields unchanged.

      In other words, ClassExtender is for adding and handling additional fields, not fields that already exist.
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/MODx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting