Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Console height allows negative number #15038

Closed
AghaSaad04 opened this issue Mar 16, 2019 · 5 comments
Closed

Console height allows negative number #15038

AghaSaad04 opened this issue Mar 16, 2019 · 5 comments
Assignees
Labels
has-pr An issue that has a pull request pending that may fix this issue. The pull request may be incomplete ui Issues relating to the user interface
Milestone

Comments

@AghaSaad04
Copy link
Contributor

Describe the bug

I have given a large negative number as a console height it has not given an error or warning but converted that number to some other number when I clicked the apply button.

To Reproduce

Steps to reproduce the behavior:

  1. Go to 'settings'
  2. Click on 'features'
  3. Click on 'console'
  4. Give a negative large number as an input for console height
  5. Click on the apply button.
  6. You'll see the difference after that.

Expected behavior

I was expecting that there would be some limit or range of the console height and that input field would not allow negative number, as console height cannot be negative.

Screenshots

Before applying:

image

After applying:

image

Server configuration

  • Operating system: Windows
  • Web server: XAMPP
  • PHP version: 7.3.0
  • phpMyAdmin version: 4.8.5

Client configuration

  • Browser: Firefox
  • Operating system: Windows
@williamdes williamdes added the ui Issues relating to the user interface label Mar 16, 2019
@ibennetch
Copy link
Member

We should check lower and upper limits, as mentioned in #15035.

@ibennetch
Copy link
Member

Related to: #15035.

@apoorvkhare07
Copy link
Contributor

@ibennetch @williamdes @AghaSaad04 The configuration for validating console height goes like $cfg_db['Console']['Height'] = 'integer'; in config.value.php. Which defines it as a PHP integer value which can have value between -2,147,483,648 to 2,147,483,647 only. This is the reason for this issue as well as #15035 .

In order to fix this we can think of a different way of validating these field. Similar to other fields where we use form ids and field names/ids to define their validation scheme.

@apoorvkhare07
Copy link
Contributor

@williamdes @ibennetch Can you please comment on in what way should I proceed with this ?
Because trying some other way to validate this might be different from the convention used for other fields of same type.
So, please let me know what way is fine for you all.

apoorvkhare07 added a commit to apoorvkhare07/phpmyadmin that referenced this issue Mar 24, 2019
Signed-off-by: apoorv <apoorvkhare007@gmail.com>
@williamdes williamdes added the has-pr An issue that has a pull request pending that may fix this issue. The pull request may be incomplete label Apr 12, 2019
@williamdes williamdes self-assigned this Apr 25, 2019
@williamdes williamdes added this to the 4.8.6 milestone Apr 25, 2019
williamdes added a commit that referenced this issue Apr 25, 2019
Fixes: #15038
Pull-request: #15086
Signed-off-by: William Desportes <williamdes@wdes.fr>
williamdes added a commit that referenced this issue Apr 25, 2019
Signed-off-by: William Desportes <williamdes@wdes.fr>
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 21, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
has-pr An issue that has a pull request pending that may fix this issue. The pull request may be incomplete ui Issues relating to the user interface
Projects
None yet
Development

No branches or pull requests

4 participants