Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1039
  • Last Modified:

change fields order in Drupal 7 register form

Hi,

On my drupal register form, I allowed users to set their own time zone. For some reason, that locale settings is appearing right in the middle of my form. Do you know a Drupal way to move it to the bottom of the form? I went to admin/config/people/accounts/fields but I canĀ“t see that field being added there. So where is it? how can I change its position?

I would greatly appreciate any help on this,


Winter
0
glepiza
Asked:
glepiza
  • 2
2 Solutions
 
itkadminCommented:
You could modify the user registration form template. https://drupal.org/node/1211520
0
 
nanharbisonCommented:
Did you try going directly to the form page and clicking on WEBFORM? It lets you move the elements around by the cross to the left of each element.
Or is this a specific content type you have created? In this case you go to Structure->content types and manage the display there.
0
 
glepizaAuthor Commented:
Hello experts, Thank you for your answers,

I ended up using the link itkadmin provided and it was quite helpful. I am printing all my fields using user-register-form.tpl.php like this:

<?php print render($form['form_id']); ?>
<?php print render($form['form_build_id']); ?>
<?php
 print render ($form['name_first']);
 print render ($form['name_last']);
 print render ($form['city']);
 print render ($form['country']); //This is the Country
 print render ($form['sex']);
 print render ($form['date_of_birth']);
 print render ($form['phone_number']);
 print render ($form['mail']);

the problem I found is that mail is not being printed out. No idea why. I did not created mail for the user registration form, it was actually placed there by the system. But when I do print_r($form) I can see the mail array like this:

[mail] => Array ( [#type] => textfield [#title] => E-mail [#maxlength] => 254 [#description] => A valid e-mail address. All e-mails from the system will be sent to this address. The e-mail address is not made public and will only be used if you wish to receive a new password or wish to receive certain news or notifications by e-mail. [#required] => 1 [#default_value] => [#attributes] => Array ( [placeholder] => xxx@xxx.com )

so I am a little confused.. why it is not outputting the input email field?

Any insight would be greatly appreciated.

Thanks

Winter
0
 
glepizaAuthor Commented:
oh, ok, I think I found the answer. It was suppose to be like this:

print render($form['account']['mail']);

thanks!
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now