课程: HTML and CSS: Creating Navigation Bars

今天就学习课程吧!

今天就开通帐号,24,700 门业界名师课程任您挑!

Making navigation go horizontal with inline-block

Making navigation go horizontal with inline-block

课程: HTML and CSS: Creating Navigation Bars

Making navigation go horizontal with inline-block

[Instructor] Making horizontal nav bars is really easy. You can do it in a style declaration or two, and ya don't need a framework to make it happen. There are two major ways of making a horizontal nav bar. In this video, I'm going to talk about the old school way of doing this with inline block. We had horizontal nav bars before there was a Flexbox that was available to us, so I'm going to show you how to do this with inline block. The advantage to inline block is that it's the simplest thing in the world, but you are going to be limited in some of the later advanced styling options, as you see later in this chapter. But if you really want a simple horizontal nav bar, there is no need to drag out Flexbox to make it happen. I can do this in like two styles. So we're going to start here with our old friends. I'm just going to make this window a little bit bigger so you can see it better. The HTML is exactly what we had from the vertical nav bar portion of the course, so you should be…

内容