Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

CSS/HTML I am working on a simple website for my class and I am having trouble with the media queries. I am trying to make

CSS/HTML

I am working on a simple website for my class and I am having trouble with the media queries. I am trying to make my horizontal navigation bar turn into a vertical navigation bar on a small screen. My code works perfectly in firefox, but is not working for other browsers. For google chrome, the media query for my navbar works perfectly on the homepage but not my other pages. I am confused why this is happening and how to fix this. I would appreciate any help I can get. My code is posted below.

html

Chade's Bicycle Company Company Calendar Contact Us

css

.navbar{ width: 100%; background-color: black; overflow: auto; }

.navbar a { float: left; padding: 5px; color: white; text-align: center; text-decoration: none; font-size: 20px; width: 32%; }

.navbar a:hover { color: #FFA500 }

@media screen and (max-width: 480px){ .navbar a { float: none; display: block; width: 100%; } }

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

What are the purposes of promotion ?

Answered: 1 week ago

Question

Define promotion.

Answered: 1 week ago