Michael Brunel 3 Posted April 29, 2019 Posted April 29, 2019 (edited) Bonjour, J'aimerais arriver à centrer la barre de recherche, quelque soit la taille de l'écran (je travaille sur 13" et j'ai aussi un grand écran 27"). Si c'est centré sur l'un grâce à la position absolute, l'autre ne l'est pas... Et pourtant je mets du positionnement en proportionnel (en em ou %...) Quelqu'un peut m'aider ? Merci beaucoup 🙏 Edited November 4, 2020 by Michael Brunel resolu (see edit history) Share this post Link to post Share on other sites
Eolia 3,127 Posted April 29, 2019 Posted April 29, 2019 #somelement { position: absolute; left: 50%; -webkit-transform: translateX(-50%); transform: translateX(-50%) } ou #somelement { position: absolute; left: 0; right: 0; margin: auto } Share this post Link to post Share on other sites
Michael Brunel 3 Posted April 30, 2019 Posted April 30, 2019 Merci ! Share this post Link to post Share on other sites
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now