Checkboxes in User Profile from Accounts

14 posts by 3 authors in: Forums > CMS Builder: Plugins & Add-ons
Last Post: May 10, 2011   (RSS)

Re: [zip222] Checkboxes in User Profile from Accounts

By Jason - May 9, 2011

Hi,

Could you please attach a copy of your .php file so I can take a closer look?

Thanks
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By zip222 - May 9, 2011

It's attached. Thanks.
Attachments:

account-php.zip 3K

Re: [zip222] Checkboxes in User Profile from Accounts

By Jason - May 10, 2011

Hi,

It looks like the issue is with this piece of code:

// prepopulate form with current user values
foreach ($CURRENT_USER as $name => $value) {
if (array_key_exists($name, $_REQUEST)) { continue; }
$_REQUEST[$name] = $value;
}


This code takes place before your update query and overwrites the values in the $_REQUEST array. You may be finding that other values on your form are not being changed either. I would suggest putting this loop lower down so that it executes only after your save has taken place.

Hope this helps
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/