Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > Adding or Editing a User from the front side of a site View modes: 
User avatar
Member
Member
glen-crookedtrailconsulting - 11/20/2013 8:49:45 AM
   
Adding or Editing a User from the front side of a site
Hi,
I have a private area on my site setup for customers to access company specific info, there are multiple users roles where a "Company Master" user is the highest level. I have it setup so the Master User can see the profiles of the other user for his company but need him to be able to add or edit users and add them to roles.

What is the best approach to getting this done? I've tried alternative forms but found out they only work within cms desk, is there a way to make an alternative form submit to the database?

thanks.

User avatar
Certified Developer 10
Certified Developer 10
josha-bpstudios - 11/20/2013 11:20:47 AM
   
RE:Adding or Editing a User from the front side of a site
Alternative forms can work on the front end as well. Look at how the normal kentico site does the my account. They have an alternate form in the users table called editprofile that is used to update the user. I just recently created the same architecture so that a person can add a company(cms.office) doctype through the front end of the site. The Kentico My Profile webpart will give you some insight to how this can be accomplished.

User avatar
Member
Member
glen-crookedtrailconsulting - 11/20/2013 11:51:06 AM
   
RE:Adding or Editing a User from the front side of a site
Thanks for the response. I did get the My Profile alternate form to work, that was no problem, but if I try to use an alt form for the "UserPublicProfile" web part to allow a user to modify a different user's profile than their own the submit button doesn't show up.

I thought I saw a post that said you can't use an alternate form on the front side for User data, does anyone know if that is correct and if there is a work around?

thanks

User avatar
Member
Member
kentico_davidb2 - 11/25/2013 2:25:26 PM
   
RE:Adding or Editing a User from the front side of a site
The webpart you are using is not meant for submitting data, therefore, it hides the button by default - please see CMSWebParts\Membership\Users\UserPublicProfile.ascx.cs
Line 186 formElem.BasicForm.SubmitButton.Visible = false;

You may try cloning and modifying the webpart (devnet.kentico.com/docs/devguide/modifying_the_code_of_standard_web_parts.htm)