Commit Graph

622 Commits (f401bea1f3345c748b46976895c1ceecad6f6258)

Author SHA1 Message Date
Dries Buytaert d958fad0d6 - Patch #40200 by Ax, Drewish, Zen et al: user_view() isn't merging view items correctly + CSS cleanup + form handling cleanup. 2006-01-26 13:43:04 +00:00
Dries Buytaert 6996292d52 - Patch #46262 by Neil: load the anonymous user on logout. 2006-01-26 08:52:24 +00:00
Dries Buytaert 794b53e195 - Patch #46137 by drumm/moshe: load anonymous user if authentication failed. 2006-01-26 08:51:10 +00:00
Dries Buytaert 017cbf5e2b - Patch #46388 by m3avrck: removed some dead code. Yay. 2006-01-26 08:43:28 +00:00
Dries Buytaert d20ed7e3be - Patch #45665 by wtanaka/moshe: removed dead code! w00t! 2006-01-24 18:32:20 +00:00
Dries Buytaert bc9cbefa30 - Patch #45729 by markus, jvandyk, moshe: fixed problem with permission checking. 2006-01-23 08:06:43 +00:00
Dries Buytaert 25f13a64c4 - Patch #45843 by markus: roles are no longer required. 2006-01-22 07:23:58 +00:00
Dries Buytaert 4da4f4c1af - Patch #44379 by Moshe: code improvements: always grant the 'authenticated user' role to authenticated users. Fixed glitch with udpate path. 2006-01-21 08:28:55 +00:00
Dries Buytaert 0ff0c4beaa - Patch #42137 by Richard: deleting non existent user blocks the whole drupal site. 2006-01-20 09:37:00 +00:00
Dries Buytaert 8c02d4ec93 - Patch #45530 by Morbus: filter_form shouldn't default to #weight 0
When a form element doesn't specify a #weight, it is assumed internally as #weight 0. However, to ensure that our form elements display visually *as they were defined in the array* we, in form_builder, count the number of elements, divide by 1000, and set that as the weight:

# Assign a decimal placeholder weight to preserve original array order
if (!isset($form[$key]['#weight'])) {
  $form[$key]['#weight'] = $count/1000;
}

The above code will set the #weights of elements that have not defined a weight to something like 0 (first element in array definition), 0.001, 0.002, and so on. However, anytime a form element *explicitly* defines a #weight of 0, that #weight is kept at exactly 0, which would cause that form element to appear BEFORE the elements that didn't have a #weight defined (and thus received a #weight such as 0.002).

Consider the following pseudo example:

$form['game_title'] = array(
    '#type' => 'textfield',
    ...
    );
$form['game_description'] = array(
    '#type' => 'textarea',
    ...
    );
$form['game_format'] = filter_form(variable_get('game_format', NULL));
return $form;

Here, we're not definiing weights on our two textfields. We then add an filter_form. The second parameter of the filter_form is $weight, which defaults to 0. After this $form hits form_builder, we have weights 0 (game_title), 0.001 (game_description), and 0 (filter_form) respectively. This is then sorted by weight, which causes filter_form (the third element in the array) to appear BEFORE game_description (0 is lighter than 0.001).

The short lesson is: explicitly defining #weight 0 for a form element is probably a bad idea. This patch changes the default #weight of filter_form to NULL, instead of 0, and also removes any other explicit setting of #weight to 0 in core.
2006-01-20 09:04:34 +00:00
Dries Buytaert 4a7abb95b6 - Patch #45312 by Robin and Zen: made theme_user_list() more like theme_item_list(), made it robust for empty lists. 2006-01-20 08:58:09 +00:00
Dries Buytaert 8b5175a983 - Patch #44754 by Zen: fixed "Who's new" block inaccuracy. 2006-01-17 09:04:20 +00:00
Dries Buytaert f649b42d9c - Patch #44767 by jvandyk: small (code) improvements 2006-01-15 16:57:56 +00:00
Dries Buytaert 776e6501cd - Patch #44210 by DriesK: made it possible to edit blocked users. 2006-01-13 19:02:38 +00:00
Dries Buytaert 403c1c0404 - Added trailing point. 2006-01-13 14:54:51 +00:00
Dries Buytaert 11b9259db0 - Patch #44507 by DriesK: consistency: email -> e-mail. 2006-01-13 07:33:13 +00:00
Dries Buytaert cccca3b17e - Patch #44261 by Kobus/Zen: drupal -> Drupal. 2006-01-12 19:29:36 +00:00
Dries Buytaert e136a247c3 - Patch #40401 by driesk: fixed incorrect form conversion. 2006-01-12 19:15:31 +00:00
Dries Buytaert 3607a2b059 - Patch #44373 by m3avrck: improved generated HTML/CSS. 2006-01-12 09:58:49 +00:00
Dries Buytaert 79cdc915ec - Modified patch #44156 by Zen: '%s' -> %d. 2006-01-10 20:11:46 +00:00
Dries Buytaert afb923a00a - Patch #36716 by m3vrick: made deleting user accounts work. 2006-01-09 19:18:46 +00:00
Dries Buytaert 7c862e924a - Patch #43668 by chx: fixed warning. 2006-01-09 18:27:26 +00:00
Dries Buytaert 6f0bd9499b - Patch #43668 by chx: fixed problem with changing usernames. 2006-01-09 14:14:39 +00:00
Dries Buytaert fb393415bb - Patch #43833 by killes: give the first user a default role. 2006-01-08 16:32:08 +00:00
Dries Buytaert 9d1d40e609 - Patch #39639 by Richard: 'users' appearing twice in menu. 2006-01-06 07:42:31 +00:00
Dries Buytaert db1e1b5388 - Patch #42541 by merlinofchaos: critical bug fix: public user registrations not always working. 2006-01-05 10:55:51 +00:00
Dries Buytaert 749284633f - Patch #42057 by hunmonk and chx: made saving user accounts work again. 2006-01-02 08:35:59 +00:00
Dries Buytaert 89e89a3b9b - Patch 42115 by Cvbge/ m3avrck: improved performance of session loading. 2005-12-31 11:50:47 +00:00
Dries Buytaert ea2d791095 - Patch 41169 by Chris: got rid of expensvie object 2 array casts. 2005-12-31 10:48:56 +00:00
Dries Buytaert d21dda89b3 - Patch #41305 by chx: user edit form submit model rewrite. 2005-12-19 10:02:33 +00:00
Dries Buytaert 63ece6f957 - Patch #29060 by tostinne/ax: added tabindex to user login page. 2005-12-11 12:53:09 +00:00
Dries Buytaert 30450039f9 - Patch #40583 by canen: make user_autocomplete function work with PostgreSQL. 2005-12-10 08:08:44 +00:00
Dries Buytaert c54234d71a - Patch #40341 by Neil: fixed problems with database schema versions.
- When user #1 creates an account (we can assume this happens only once), system.module's schema version is set to the latest availiable.
  - system_get_files_database() now includes a 'schema_version' child of each file object.
  - That new information is re-saved when Drupal re-populates the system table.
  - An array of newly-enabled modules is built, module_list() is reloaded, and the schema versions of each newly-enabled module are set to the most recent availiable. If the schema version is already set (presumably from a previous installation) it is not changed.
2005-12-08 08:40:10 +00:00
Dries Buytaert 9ccb6d7a80 - Patch #26641 by Uwe: tabs disappear in user.module settings after saving a role. 2005-12-06 12:36:37 +00:00
Dries Buytaert 26bd449860 - Patch #39576 by chx: rename '_execute' to '_submit' and '#execute' to '#submit'. 2005-12-02 15:21:01 +00:00
Dries Buytaert 0dad5d9e45 - Patch #39547 by saerdna et al.: added a 'change own username' permission. 2005-12-02 15:18:32 +00:00
Dries Buytaert b8ae0b3218 - Patch #38981 by Robert: add permission to enable/disbale theme switching by users. 2005-11-30 11:09:38 +00:00
Dries Buytaert fff9a51352 - Patch #38945 by wtanaka: made the login block redirect back to the original page. 2005-11-28 12:31:47 +00:00
Dries Buytaert f532273a13 - Patch #38412 by m3avrck: fixed problem with creating first account. 2005-11-22 21:00:40 +00:00
Dries Buytaert ecc279aef6 - Patch #37416 by Zen: make auto-completion of usernames work with short names. 2005-11-21 18:36:12 +00:00
Dries Buytaert 0bb347ccbe - Patch #38248 by hunkmonk: updated the user login form to the forms API's _execute model. 2005-11-21 09:17:04 +00:00
Dries Buytaert 48929eba7a - Patch #37738 by Junyor: fixed problem with Drupal not properly unsetting $user on logout. 2005-11-15 20:47:06 +00:00
Dries Buytaert ad74b700c4 - Patch #32669 by DriesK: split blocking users from 'adminsiter access'. 2005-11-14 21:49:47 +00:00
Dries Buytaert aeed4cd8e4 - Patch #35644 by webchick: forms API simplificiations. 2005-11-12 11:26:16 +00:00
Dries Buytaert 64a617c208 - Patch #26249 by Morbus: improved handling of temporary files/directory.
If your module uses variable_get('file_directory_temp', ...) or
  variable_get('file_directory_path', ...) please update it to use the new
  API.

  A list of affected modules is available at http://drupal.org/node/26249#comment-54194.
2005-11-12 09:23:50 +00:00
Dries Buytaert 7dd24bec5c - SQL query maintenance: '%d' -> %d. 2005-11-12 09:14:30 +00:00
Dries Buytaert a8b218827a - Patch #26139 by webchick / Kieran / documentation team: improved admin help of core modules! / 2005-11-01 10:17:34 +00:00
Dries Buytaert 4af960646d - Patch #35648 by asimmonds: fixed permissions page. 2005-10-31 13:37:38 +00:00
Steven Wittens 08f8876f48 - #35440: Fix user 1 login bug after forms api 2005-10-28 00:37:06 +00:00
Dries Buytaert f6764cfbd8 - Patch #30930 by m3avrck/deekayen: cured PHP5 warnings. 2005-10-22 15:14:46 +00:00
Dries Buytaert a5f9391550 - Modified patch #34472 by Moshe: uid=1 does not redirect to edit page after registration. 2005-10-21 09:30:14 +00:00
Dries Buytaert f905ab181f - Patch #34031 by drewish: delete button on the edit user account form should be after the submit button. 2005-10-21 09:07:12 +00:00
Dries Buytaert 1c0b946535 - Modified version of patch #33348 by wolff: clean URL emitted when creating first user. 2005-10-13 10:39:56 +00:00
Steven Wittens 5f0e0f3649 - #33433: More form API fixes, and error handling improvements by Chx. 2005-10-13 10:02:31 +00:00
Steven Wittens 1b1a2d7750 - Restore user login block alignment (form api patch undid some recent class/id changes) 2005-10-11 20:52:16 +00:00
Dries Buytaert 75fe6b6c0a - Patch #33752 by chx, adrian, et al: another batch of form API changes/fixes. 2005-10-11 19:44:35 +00:00
Dries Buytaert fd96728f3c - Second batch of form API fixes by chx. 2005-10-09 10:39:15 +00:00
Dries Buytaert 27625fcf83 - Patch #31341 by kbahey: delete a user's session when the user is deleted. 2005-10-07 06:53:25 +00:00
Dries Buytaert 7e1527ee61 - Patch #29465: new form API by Adrian et al.
TODO:
  + The contact.module was broken; a new patch for contact.module is needed.
  + Documentation is needed.
  + The most important modules need to be updated ASAP.
2005-10-07 06:11:12 +00:00
Dries Buytaert c267c749e7 - Patch #32669 by DriesK: added an 'administer access control' permission.
In several setups, one wants to grant the 'administer users' permission to certain roles (for example to forum admins), however without allowing those users to change permissions on the 'access control' page, and without allowing them to change the users' roles (so that they can't, for example, promote themselves to admin).
2005-10-01 13:42:00 +00:00
Dries Buytaert 67e68fc679 - Patch #28786 by Neil: move pagers out of table. 2005-09-24 07:53:26 +00:00
Dries Buytaert ce3b6d4eee - Patch #28301 by jjeff: show tooltip when hovering over a permission. Temoprary
solution until we have a better permission page.
2005-09-15 21:45:21 +00:00
Dries Buytaert 4005922332 - Patch #31123 by Ber: make it easier to theme the user profile pages. 2005-09-14 21:16:00 +00:00
Dries Buytaert cead2e37b1 - Patch #26033 by m4avrck: fixed PHP5 warnings (call by reference) 2005-09-08 19:46:05 +00:00
Dries Buytaert f3cb254cb7 - Patch #23536 by chx: custom registration fields should appear on admin/user/create. 2005-09-08 19:32:31 +00:00
Dries Buytaert 013b73e6ec - Patch #30122 by m3verick: changed include_once()'s to include "./$file"
for performance's sake.
2005-09-08 19:19:01 +00:00
Dries Buytaert 16262e03d5 - Patch #28320 by Neil: improved the HTML/CSS of the user login block. 2005-09-07 20:56:00 +00:00
Dries Buytaert bcd59aa0dd - Patch #24617 by Morbus: fixed incorrect access checking. 2005-09-07 20:41:38 +00:00
Dries Buytaert 298b403bf1 - Patch #18252 by tostinni: don't try creating the picture directory when picture support is not enabled. 2005-09-06 19:22:50 +00:00
Dries Buytaert 7f08b766aa - Patch #30382 by Robert: removed unused variable by ''. 2005-09-06 19:10:50 +00:00
Dries Buytaert 7b8a409675 - Patch #29385 by chx: no ?> add end of files. 2005-08-25 21:14:17 +00:00
Dries Buytaert 78317bca79 - Patch #27897 by kubaZygmunt: fixed PHP warning. 2005-08-11 13:52:44 +00:00
Dries Buytaert 192dcd04ba - Patch #18778 by Gerhard/Olen: sort users by creation date rather than user ID. 2005-08-10 20:46:29 +00:00
Dries Buytaert 5270f7fd88 - Patch #28599 by Cvbge: fixed typo in documentation: 'user' -> 'used'. 2005-08-10 20:38:57 +00:00
Steven Wittens 64299d7455 - #27852: redirect to user edit page on first log-in 2005-08-05 01:18:39 +00:00
Steven Wittens 3feef48da2 - #28154: remove useless /view from user results 2005-08-03 23:23:48 +00:00
Dries Buytaert 7625a4e91a - Patch #27737 by Gerhard: format_name($object) -> theme('username', $object).
Usernames can now be themed; eg. an icon/avatar could be added.

  TODO: update contributed modules + update the migration docs.
2005-08-01 05:14:05 +00:00
Steven Wittens 22479d8761 - Add some Unicode checks to username validation 2005-07-31 21:54:39 +00:00
Steven Wittens 2a561f3bc1 - #16705: Make user_access always return a boolean. 2005-07-29 21:34:56 +00:00
Steven Wittens 8de43c320a - #27694: Correct username validation. 2005-07-29 07:18:36 +00:00
Steven Wittens 11a4aba9a6 - #26688: Add mbstring support to Drupal and clear up string handling fuzzies. 2005-07-25 20:40:35 +00:00
Dries Buytaert 7480e9ac3c - Modified patch #27131 by DriesK: removed some cache_clear_all()s. 2005-07-23 05:53:43 +00:00
Steven Wittens 02ca763ea0 - Fix PHP notice (killes) 2005-07-20 00:50:34 +00:00
Dries Buytaert 7ee24ccfe4 - Patch #27062 by nysus: improved the help text of the 'access control' page.
Generally improves readability; gets rid of technical jargon; provides
  concrete example; provides suggestions for how permissions can be used.
2005-07-19 17:57:55 +00:00
Dries Buytaert d96e7e0bbb - Patches by Ber: move user settings and node settings to admin/settings. 2005-07-03 16:41:42 +00:00
Dries Buytaert 58aee8cdad - Patch #25603 by Stefan: made the sizes of forms consistent.
TODO: document the defaults in the PHPdoc comments.
2005-06-27 18:33:33 +00:00
Dries Buytaert 5365db7e07 - Patch by Robert: fixed problem with username blocking. 2005-06-23 19:26:51 +00:00
Dries Buytaert e7cc200eeb - Patch by deekayen: roll back permission patch. 2005-06-23 05:10:38 +00:00
Dries Buytaert f3a9a99570 - Patch #25121 by Robrecht J.: changed itemized lists with hardcoded CSS to definition lists. 2005-06-21 18:58:27 +00:00
Dries Buytaert 22ea50dfec - Patch #21566 by deekayan: fixed user_access() function returning a string and not a boolean. Also improves performance of user_access(). 2005-06-21 18:45:30 +00:00
Dries Buytaert 8f82f92a10 - Patch #25398 by Ber: drop.org -> drupal.org. 2005-06-21 18:22:26 +00:00
Dries Buytaert 4c77761efb - Patch #3962 by deekayen: improved error message when a blocked user attempts to login. 2005-06-21 18:21:08 +00:00
Dries Buytaert b3336096a3 - Patch #24766 by deekayen (David): fixed user module showing the epoch instead of 'never'. 2005-06-19 09:06:02 +00:00
Dries Buytaert 1474632aa0 - Patch #24135 by Moshe: made it possible to ban visitors based on hostname/IP. Banning visitors can either be done from the 'access control' pages, or directly from the statistics pages. This feature is very convenient to block badly behaving crawlers. 2005-06-07 18:54:37 +00:00
Dries Buytaert 263b7e230d - Fixed registration bug. 2005-06-01 20:21:35 +00:00
Dries Buytaert f68f9111ca - Patch #23633 by Moshe: improve grouping in default profile page. 2005-05-26 19:03:05 +00:00
Dries Buytaert e579f4d407 - Patch #23588 by Ber: fixed incorrect call to theme_user_picture. 2005-05-25 19:54:49 +00:00
Steven Wittens 58bddf8abc * cue Star Wars theme tune *
Return of the JavaScript!

- #22519: form_autocomplete(): Ajax based autocompletion. Currently used for user names and folksonomy tags.
2005-05-24 06:00:22 +00:00
Dries Buytaert 0de88f50ba - Patch #23383 by Ber: added theme_user_list() function. 2005-05-23 21:23:04 +00:00
Dries Buytaert 2a744f8950 - Patch #11791 by kps: trim passwords to avoid copy-paste mistakes. 2005-05-21 11:57:59 +00:00