I have a standard website, and when the user zooms in (CTRL +), how can I prevent elements from resizing?
It is mostly used with textarea and div elements. To disable resizable property of an element use resize to none. It is the default value.
min-width: 100%; This will freeze the width, you can do the same for height too.
There's no way I know of to prevent items from scaling when a user zooms in. There may be a way to catch the zoom event and size elements accordingly, but it won't work in all browsers.
And to state the obvious - people zoom in because they can't read/see it at normal zoom. Pleeeaase don't break standard behaviour. It's there for a reason.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With