1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 22:10:45 +02:00

Merge pull request #4021 from marc1706/ticket/14272

[ticket/14272] Use html5 valid input elements

* marc1706/ticket/14272:
  [ticket/14272] Allow input of floats for filesize
  [ticket/14272] Use input type number instead of text in avatars
  [ticket/14272] Assign min and max values for avatar driver settings
  [ticket/14272] Define min and max values for avatar width and height
  [ticket/14272] Disable not toggled form elements
  [ticket/14272] Make sure phpbb_avatar_manager was defined
  [ticket/14272] Remove useless check
  [ticket/14272] Fix invalid or missing min/max settings
  [ticket/14272] Assign min/max for all allowed types
  [ticket/14272] Only use maxlength and size for allowed input elements
This commit is contained in:
Tristan Darricau
2016-03-27 13:34:17 +02:00
39 changed files with 139 additions and 93 deletions

View File

@@ -1538,6 +1538,13 @@ phpbb.toggleSelectSettings = function(el) {
var $this = $(this),
$setting = $($this.data('toggle-setting'));
$setting.toggle($this.is(':selected'));
// Disable any input elements that are not visible right now
if ($this.is(':selected')) {
$($this.data('toggle-setting') + ' input').prop('disabled', false);
} else {
$($this.data('toggle-setting') + ' input').prop('disabled', true);
}
});
};