Password field name change in Drupal7 - drupal-7

How to rename the registration password field in drupal7?

You need to use the hook hook_form_alter(). There are a lot of tutorial on how to use form_alter to change form elements, for exemple this one (randomly found)

Related

Azure B2C TrustFrameworkLocalization.xml and passing the attribute name on custom policy for errors

I'm trying to pass the display name of all my fields to any of the inputs that fail when a user tries to sign up, but fails to for missing an input box?
The only Microsofts docs I could find was to just add the {0} and it would display on over the input. But it just puts the actual the actual text of '{0}'
<LocalizedString ElementType="UxElement" StringId="required_field">This
information is required {0} . </LocalizedString>
Am I missing a setting to activate this to pass the display names to the screen?
Thanks,
Adam
It’s not possible to configure this, other than using custom JS.

Show and hide server-side errors in AngularJS 1.3+ forms

I'm using the Angular framework with Angular Material controls in my recent application. I'm looking for a good solution for the following problem:
A form form with an input field named nickname is shown to the user. After the user has chosen a nickname and submitted the form, the server checks whether the nickname has already been taken. In that case, it returns an error to the Angular client.
To show an appropriate error to the user, the code then calls form.nickname.$setValidity('nicknameTaken', true). The new ngMessages module is used to display the error to the user. Further form.$isInvalid is used to disable the form controls to prevent the user from resubmitting the invalid nickname.
My problem is now the following: I'd like to have the error nicknameTaken automatically being removed as soon as the user begins to edit the form fields again. What is a good way to do this? Is there a predefined route to go when it comes to server-side validation errors of this kind? (Note that I am not asking for asynchronous validation because I only want to contact my server when the form is actually being submitted.)
I would write a normal validator directive instead. Something like
<input blacklist="takenNickNames" .../>
This directive would simply add a validator to the input, and this validator would make the input invalid if the model value is contained inside the given takenNickNames array (and valid if it's not present).
The takenNickNames array would be empty initially. When the form is submitted and the error comes back, the controller would add the invalid nick name to the array.
So, every time the user would enter something, the validator would be triggered, and would set the field valid or not, based on the taken nicknames stored in the array.
Here is a working example.

How can I check to see if a username is already used with AngularJS?

In my form I have a username field that is user for registration. I would like to make this trigger an error message on the field. Something like the error message I would get if I did not enter a value on a field with ng-required.
Can someone tell me how I can make it so that when a user leaves the field then an HTTP request is sent to the database to check for an existing username and then if present an error condition is set for that field.
I am not really looking for specific HTTP request code but just even some pointers would be a big help.
Here's a nice guide on how to check a name field using custom directive and new features from 1.3

Drupal7 Displayed Username different from Username Entry Field

On our Drupal 7 site, we're trying to force Drupal to use a certain username- First Name, Last Initial - no matter what the user puts in the username field on the user form. Currently, there are fields for Username, First Name, and Last Name. Does anyone have an easy way to do this? It would also be nice if the user profile's URL would take be forced to use the Drupal-created username.
I've looked around and haven't seen any questions on this- let me know if I missed one!
There is a module that do just that RealName and it fairly easy to use and this is the documentation for the module if needed.
and you can alter the user profile link with Pathauto to what ever you want.

Show Opportunity Stage Name Picklist read only based on user role

I am new to Salesforce and need an idea how is possible that suppose I have one user named "ABC".I don't want to show the Opportunity StageName picklist when "ABC" user login in editable form or just want to show the StageName value in textfield or anything other.
I tried to set the permission under setup but not achieved what I want. I just came to know that formula field or formula will used for that, as I am new to Salesforce so I unable to create a formula field.
Thanks.
To achieve this You should try field level security settings:
https://login.salesforce.com/help/doc/en/admin_fls.htm
You can select per field /profile combination which fields are visible and which are editable.
You cannot apply FLS on system required fields neither can you make them read only on the page layouts. You also cannot remove such fields from page layout. In short you are stuck with this field for ever!
I wish Stage was not a required field.
Mitesh

Resources