Bro Code Bro Code Home About Products Contact This is the Home page Lorem ipsum dolor sit amet consectetur adipisicing elit. Ipsam minus eveniet recusandae dicta similique numquam voluptas quos tempore cupiditate pariatur, laudantium fugit alias quia veritatis nesciunt quaerat molestias adipisci assumenda. /* style.css */ body{ margin: 0px; } main{ margin-left: 20px; margin-right: 20px; } h1{ text-align: center; } .navbar ul{ list-style-type: none; background-color: hsl(0, 0%, 25%); padding: 0px; margin: 0px; overflow: hidden; } .navbar a{ color: white; text-decoration: none; padding: 15px; display: block; text-align: center; } .navbar a:hover{ background-color: hsl(0, 0%, 10%); } .navbar li{ float: left; }
@emmanuelanallemina4321 Жыл бұрын
How to I copy the code
@rayyanabdulwajid7681 Жыл бұрын
It's better to use display flex than float.
@iamaffan09010 ай бұрын
i like it
@walidwalid16699 ай бұрын
Thank you 🎉
@Nocontenthere10398 ай бұрын
Brotha, where is the CSS file?! I really need it for my new project 😢😅
@StopWhining491 Жыл бұрын
You've got the best step-by-step videos. Thanks for all your work and sharing.
@shanepelletier234710 ай бұрын
for anyone trying to make this responsive: body{ margin: 0px; } main{ margin-left: 20px; margin-right: 20px; } h1{ text-align: center; } .navbar{ background-color: hsl(0, 0%, 25%); } .navbar ul{ list-style: none; padding: 0px; margin: 0px; display: inline-flex; } .navbar a{ color: white; text-decoration: none; padding: 15px; display: block; text-align: center; } .navbar a:hover{ background-color: hsl(0, 0%, 10%); } this uses flexbox and added .navbar{} so the background color stretches across the webpage
@flinch971010 ай бұрын
You're a lifesaver. Thanks!
@Kieselsteo3 ай бұрын
Yo bro it seems like u know about this. Can u help me with something ? I did everything like in the video but my Navigation Bar is not going horizontally. So picture it like that. It is vertically and the elements still take up the entire lenght of the browser as if they were div elements. How do I solve this bc I literally made everything exactly like in the video ...
@richardolajiga3176 Жыл бұрын
This guy is too good with his explanations
@l-fitness3590 Жыл бұрын
It’s straight to the point and easy to understand definitely one of the best
@1stlyrics-s9cАй бұрын
This video humbles me lol. I do a lot of style, while this guy just make it simple and efficient. goodwork
@devd3 Жыл бұрын
bro cooked and I ate
@Fl_ninja Жыл бұрын
💯 Every vid
@Enryu071 Жыл бұрын
Yum
@Luxorafashion0009 ай бұрын
I Also Eat but I learn the recipe as well
@evanauli80929 ай бұрын
ZANKS ZQADDDYIE
@rizwinrz84689 ай бұрын
😂😂
@Legomaniac359 Жыл бұрын
Straight to the point. Thank you!
@jakry_apexlegends Жыл бұрын
You are a gentleman and a scholar. Thanks
@Freeteechingresiurce87409 Жыл бұрын
Very good person
@supreme_wx24998 ай бұрын
IVE BEEN LOOKING FOR THIS SO MUCH. Im so glad l found you bro
@Dr.Amirdharajah20 күн бұрын
Crystal Clear Explanation… ❤🎉
@deborahtshiyeya3078 ай бұрын
Thank you for explaining while showing us how to do it. This makes it easier to understand. You are the best❤❤
@maricarlacerna5841 Жыл бұрын
Finally! A working code! thank you very much for this @Bro Code you save me from failling
@happytofu53 ай бұрын
Oh man already the third video I watch from you today. You really cover it all, thanks bro!
@GirlActober2 ай бұрын
I want to do options and in inside the options do another option, how can I do it??
@happytofu52 ай бұрын
@@GirlActober I found the video "The Only CSS Layout Guide You'll Ever Need " by EdRoh very helpful on how to do layouts
@GirlActober2 ай бұрын
@ اين يمكنني ان اجده ؟
@GirlActober2 ай бұрын
@ where can I find this?
@happytofu52 ай бұрын
@@GirlActober its here on youtube, I can't link it though because youtube deletes comments with links, just search for the title
@CapDrew4 ай бұрын
Great explanation. You made that look easy, I just have to make a couple of these to get it down so I don't forget.
@mr.shredder5430 Жыл бұрын
just the thing i needed thanks for sharing this content👍
@user-dk9of1ok1n8 ай бұрын
You are the best Bro. Stay blessed 🙌
@InterestingLake2 ай бұрын
Awesome tutorial, thanks!
@PriggarGamingАй бұрын
I wish i found 2 years ago... I made a website for school I literally just used h1 and out hyperlinks in it... Because i didn't knew anything at all... Well... Atleast its helping me now that I am in college and now have to study the same as i did last time Because i don't know University make that syllabus that way... And now i am finally learning something i took lazy way out in class 10
@ShaddieMello4 ай бұрын
Bro code is elusively elegant as ever
@amandapanda3750 Жыл бұрын
Thanks so much. I've been searching for sooo long to find out how to do this.
@bamanbamni Жыл бұрын
it is important to use main (can we use a div instead of main for main content )
@asa-od9pu10 ай бұрын
How do I center the navigation br in the center of my webpage, it wants to all shift to the side but I want it to be about 100 pixels long and center with h1
@waltermitty413210 ай бұрын
I don't understand why you added "overflow:hidden" to the CSS file? What is its purpose in this navbar?
@realnoscope10 ай бұрын
so it doesn't show a scroll bar on the nav bar
@yehohanan7738Ай бұрын
Thanks for this tutorial ❤❤❤
@asalmda70105 ай бұрын
BRO YOU'RE AMAZING, HELPING ME SO MUCHHHH, THANK YOUUUU
@asterinology9 ай бұрын
the tutorial is simple and straightforward. thank youuuuuu❤❤❤
@3210egh7 ай бұрын
It helped me a lot. Thank you very much. Let's take a follow-up lecture. Lee Jong-hoon from the coast
@domlosurdo3432Ай бұрын
Tough. I was not aware of the nav element and also did not do a ul. I did it the hard (and stupid, apparently) way of setting up individual buttons to create a horizontal navbar. It looks and functions the same but is a lot of extra code. Good news is I learned a lot from it :)
@SmartKhani7864 ай бұрын
wow great work you've done❤ i subscribed your channel.
@amitcoc784011 ай бұрын
Best teacher 🧑🏫
@Tempest280003 ай бұрын
Hi! Senior high school student here! You dropped this king 👑 🗿
@Procode-w2r5 ай бұрын
you should be my coding teacher keep it up
@Asulescu11 ай бұрын
May god bless you ! Thank you save my life seriously
@ØgbDêcênt3 ай бұрын
Thanks man you're our a real bro 💪
@louismario66Ай бұрын
Question...what if you want the home to be at the right by the extreme end and the contact at the left extreme end while the product and about at the middle How will you do it?
@VijaykumarA-o8v11 ай бұрын
Hi Bro Codez, Your tutorials is awesome. Please clarify my doubt, Some of the using Flexbox and Grid to align the navbar button but you didn't use that so please explain which is correct.
@felcynchannel84010 ай бұрын
I believe you want to use flex box to make it more responsive
@HafeezKhan-it3bl3 ай бұрын
Bro your crazy man I like you thanks for help ❤️❤️
@gian-mm9kr Жыл бұрын
How can I center the nav bar ? the only way i was able to get was creating a div section.
@dmojela1625 Жыл бұрын
Best teacher.... 👌
@abdullahbiswas1 Жыл бұрын
Thank you for the content
@MdHossainAhmed-sc4ui Жыл бұрын
Very helpful video
@biggstreamsАй бұрын
great video!
@mohaimenpotawan284210 ай бұрын
very kind blogger
@ayannasir6653 Жыл бұрын
Make a video on how to put "LOGO" and adjust its height and width using "CSS" with according to our needs?
@Pankajweb9967 ай бұрын
Exactly same problem i was facing😂
@Thegoal2.P7 ай бұрын
@@Pankajweb996 just use img
@Thals_MK Жыл бұрын
THANKS I NEEDED THIS SO MUCH FOR SCHOOL PROJECT🎉🎉🎉🎉🎉
@OceanFanatic7 ай бұрын
Helpful video. Thank you
@iangabriel1031 Жыл бұрын
This is what i need!! Thank you so much bro i will subscribe you
@princeshukraan309910 ай бұрын
Very good,I love him
@JanviMali1559 ай бұрын
Amazing work
@nickpage15757 ай бұрын
thank you for this! i am battling constructing a website for my web development course and i am struggling pretty badly. Now i need to fight ad figure out how to create the other sections of my site and link them to the main page...Any tips?
@NnFace-ql3jo Жыл бұрын
best coder
@Blu3ligh77 ай бұрын
100/10 great video!
@sanjayagnihotrii51268 ай бұрын
amazing brooo thumbs up for bro code share
@muhammadsulaiman41533 ай бұрын
Thank you sir ❤
@chigozie63336 ай бұрын
Thank you Bro Code. I practised this tutorial and observed that when i floated the navigation bars RIGHT the navigation bars were not arranged in sequence as described in the script. I had no problem when i floated LEFT. How can i correct this?
@paIeville4 ай бұрын
maybe instead of using the float and overflow properties like he did, try using display:inline on the li elements and using text-align:right on the ul. but i cant test rn so dont know if it works edit: worked for me
@joseluisMartin3 ай бұрын
I've got a question, how did you add style.css to the new tab? Thank you.
@yashaswimohod964711 ай бұрын
Can you make a proper responsive website. It will be easy to add in my projects.😉
@hertechera11 ай бұрын
Appreciate this, thank you
@prithurajvidyadas2850 Жыл бұрын
why did u use "overflow:hidden" can u explain that part like what did u hide exactly?
@omairtech6711 Жыл бұрын
I want an answer to this as well. He did not explain at all.
@devd3 Жыл бұрын
it prevents horizontal scrolling
@memefromtheinternet Жыл бұрын
@@devd3 thanks I also needed that
@pholcastaneda3699 Жыл бұрын
@@devd3 But why does setting the property float:left make it disappear? I don't get it
@cuteminired655011 ай бұрын
Yes exactly @@pholcastaneda3699
@NeerajKumar-j8y7bАй бұрын
The navigation and CSS styling in not working on a chrome book. What could be the reason?
@kiddReyes11 ай бұрын
If I want to float right why does my words reverse
@gamiltadross280720 күн бұрын
Just wow
@NaftaliKipkoech Жыл бұрын
Bro had to earn my subscription and he did it
@RickWoellert3 ай бұрын
Yeah Bro I really learn so much from your Videos. I have another Version instead of the float: left you can change the display to inline-block for the (a) and (li): And i also change the margin and padding so the ul is in the center( no is not in the center when i change the size of the screen where the index.html is opened. How to center the horizontal navigation bar? Maybe with flexbox but the topic comes later. style.css /* No Margin for the Navigation Bar */ body { margin: 0px; } /* The content after the Nav Bar should have a margin */ main { margin-left: 20px; margin-right: 20px; } /* Header of the Website */ h1 { text-align: center; } /* The ul content inside the navbar */ .navbar ul { list-style-type: none; /* Remove the bullet Points in front */ background-color: hsl(0, 0%, 25%); padding: 0px; /* Size inside the ul bar. */ padding-left: 70px; /* to center */ margin: 0px; overflow: hidden; /* Keeps content in the navbar ul */ } .navbar a { color: white; text-decoration: none; /* remove the underline */ padding: 15px; /* Space between each a Element */ display: inline-block; /* Changed from block to inline-block */ text-align: center; } .navbar a:hover { background-color: hsl(0, 0%, 10%); } .navbar li { display: inline-block; /* Changed from float to inline-block */ }
@GirlActober2 ай бұрын
I want to do options and in inside the options do another option, how can I do it??
@suyashman7964 Жыл бұрын
Epic bro
@AdeelAhmad00078 ай бұрын
Nice Video
@mrkaliyaofficial9 ай бұрын
Nice bro
@Teymur.17.footballl24 күн бұрын
Bro can someone tell me why my code is not working for example I click the about button but the text is the same even though I changed it
@arunimarajesh61447 ай бұрын
Why did float:left and overflow: hidden make the nav bar horizontal? 4:05
@sandy_mind5 ай бұрын
I also have the same doubt someone clear it
@AdeelAhmad00078 ай бұрын
amazing
@Angle_gamer9805 ай бұрын
Which text editor you have installed?
@arthurlabrador9162 ай бұрын
Thank you
@AmmarAlBalawi-o1b2 ай бұрын
how i turn it in button and make it work ?
@hitoshiasakura91093 ай бұрын
Bro explained it way more precise
@SpongeknobSquarenut Жыл бұрын
instead of using colors for navigation bar can i use images?
@ayushlimbu8044 Жыл бұрын
Thanks bro!
@asifirtezaratul38937 ай бұрын
Bro can you explain the "overflow: hidden" part? How did that fix the problem there?
@karol32096 ай бұрын
So it doesn't show a scroll bar on the nav bar.
@agonluta96724 ай бұрын
When you use float: left; on the elements, the parent no longer recognizes the height of its floated children, because floats are taken out of the document flow. As a result, the collapses, and the background color of the disappears, making it look white (or transparent). When you add overflow: hidden; to the .ul1, it forces the parent to recognize the height of its floated children again. This works as a kind of hack to "clear" the floats without needing to manually add a clearfix. Here's why it works: overflow: hidden; makes the container expand to enclose its floated children, solving the collapsing issue without needing to apply the more explicit clearfix methods. Why the overflow: hidden; works: Without it: Floated elements are removed from the normal flow of the document. The container doesn't stretch to wrap around its floated children, causing it to "collapse" in terms of height. With it: The overflow: hidden; forces the container to calculate its dimensions based on the floated elements inside it, so it correctly stretches to enclose its content.
@Games-games506 Жыл бұрын
you are legend - thanks
@nathansimelane56211 ай бұрын
What have I done wrong because my display:block and text align center is not working
@ayeshasiddika125211 ай бұрын
great
@brightasinde7034 Жыл бұрын
Sir Please am looking for how to creat contact form email, text using nave element instead of div element ?
@watsonhaymont5 ай бұрын
thumbs .. nailed it ! lol
@ethioictmedia Жыл бұрын
it is Good
@jokosinh6 ай бұрын
Interesting
@hamzeizmail4422 ай бұрын
sir its not showing copy option in html
@johnvincentbaguion83389 ай бұрын
When we are outting "padding" its turning red, not blue
@withinsyn74824 ай бұрын
Thank you!!!!!!
@bonnimahitani49985 ай бұрын
yo what website editor u using
@KaranSingh-zz9rg6 ай бұрын
thanks sir
@why_milinnd_014 ай бұрын
Why dont you just use display flex ??
@kingsleydied3 ай бұрын
does anyone elses nav bar stop working when they put it in a ordered list? I don't know how to get it to work
@oussamaidrissi95367 ай бұрын
Thanks you
@chamnabkem5459 Жыл бұрын
Thank you!!!
@Yeager_0016 ай бұрын
Bro code ❌ Pro code ✅🤩🥵
@Compilationguy17273 ай бұрын
The second a copy the html page the codes stoped working
@semiloreolowe29625 ай бұрын
Please what extension do you use
@lutfirighthereАй бұрын
Do you mean coding software? He uses visual Studio
@boss-ut6yw7 ай бұрын
question what is padding what is margin ?
@Irin_yigir6 ай бұрын
padding: is the space between the block content and it's border; Margin: is the space between the block itself and the borders of the page;
@boss-ut6yw6 ай бұрын
@@Irin_yigir thanks
@EnderKyo Жыл бұрын
My styled nav bar isn’t showing up on my second page the links are there it just isn’t styled like the home page, any thoughts?
@EnderKyo11 ай бұрын
@@bqadrat thanks a bunch man I appreciate your comment but I already passed the class so I’m set 😂