How can I move the logo, center, right elements inside the header element?
For further actions, you may consider blocking this person and/or reporting abuse
How can I move the logo, center, right elements inside the header element?
For further actions, you may consider blocking this person and/or reporting abuse
ng-news -
varzoeaa -
Hòa Nguyễn Coder -
Farouk -
Top comments (10)
Can you share what your html looks like? Something like a codepen would help us help you 😊
Oh here :)
codepen.io/Sampsa96/pen/mdVPoVE
OK great!
So if I understand your question correctly you want to achieve this:
In which case, take your three divs:
header_logo
,header_center
,header_right
and move them inside theheader
div. So you now have:That puts your elements inside the header. However, they will naturally appear one below each other. To change that so they flow left to right across the page, you can change your CSS and make use of flexbox.
Add this extra line to your header div CSS:
This will achieve the screenshot I posted. Hopefully I didn't misunderstand and this is of some help - but let me know if not!
Yes! Thank you, I couldn't find any good guides online..
No problem! Glad I could help 😁
I noticed that the page is displayed correctly, but for some reason is not scaling if I look at it with a smaller display.
So all of your items have a fixed with (e.g. the header is 960px wide). This means regardless of the size of screen, it will occupy 960px. If you want it to be response, try using a percentage, e.g. make the header 100% and the items inside 33%
You can also look up 'CSS media queries' which will find you further resources about making a responsive design
Woaw, please provide some code or context, I don't really known what you are trying to do right now :)
Ohh I thought I attached the picture. There :)
dev-to-uploads.s3.amazonaws.com/i/...
Thanks, someone have already answered your question :)