I have an AJAX on my site, but when a scrollbar is added to a page, the site shifts, how to make it always in one place when there is or no scrollbar.

2 answers 2

As an option - to fix the vertical scroll so that it is always: html {overflow-y: scroll; }

  • No, this is not an option - ashorva

You can also disable it if it is not needed. In general, try with absolute positioning, for example: .element_class{position: absolute} , but this is a bad way out.

I, if I don’t get something in css, I just rewrite it and structure it so that everything is absolutely clear.