Mobile menu
-
Hello!
I have question, how to change mobile menu color without changing header color?
I want my header to stay transparent, but at the same time I want that my mobile menu can be seen and for that I need to change the background color. Is it possible to change the color separately from header?Website: [ redundant link removed ]
Looking forward to hear from you!
Thank you!- This topic was modified 2 years, 1 month ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Everything else WordPress topic
The page I need help with: [log in to see the link]
-
Hi @elfeja Yes. It is possible to set background color in mobile and set transparent in desktop. You can use media query as shown below.
@media (max-width : 767px){ ul#mobile_menu { background-color:red; } }
Please change color red with your desired color. You can add other css in this media query to make mobile menu more attractive.
Thank you.
I tried this code, but sadly nothing changed.
What else I can do?
I need to change color only in the red area.Hi @elfeja Your link is not accessible. Can you please share screenshot so I can give you exact css?
Hi!
I will share screenshot again – https://elfasterapija.lv/wp-content/uploads/2022/07/IMG_9936.png
I hope you can see it.
Thank you very much!!!
Elfa.Hi @elfeja Your screenshot link is accessible but not able to see red area where you want to change color. Also let me know where you are putting media query in css file.
Oh, sorry, my mistake.
Here will be the right photo –
https://elfasterapija.lv/wp-content/uploads/2022/07/IMG_9917.jpgAbout media query I’m not sure I understand completely what is that?
Hi @elfeja Yes. This screenshot link is accessible. I gave you proper css earlier for your required mobile menu section. Media query is used to set css for particular device size. Just put this css at the end of your css file and check.
@media (max-width : 767px){ ul#mobile_menu { background-color:red; } }
Hello!
Thank you, I put this in css, but nothing changed.
I can’t figure out what isn’t working here.Oh, finally. I just made some changes in your given code and now everything works!
Thank you!
- The topic ‘Mobile menu’ is closed to new replies.