CSS HTML Coders saidia hapa

Mi ni beginner in coding. Najaribu kulearn basic html and css. How do i make navigation bar to stay on the top when i select a page kwa the menu ya navigation bar. coz when i click on it it disappears. See my screenshots za codes and what i mean below
[ATTACH=full]308743[/ATTACH]
when i select news…this is what happens it opens the page but the navigation bar disappears
[ATTACH=full]308744[/ATTACH]this is how my html and css codes inakaa

[ATTACH=full]308746[/ATTACH]
css files
[ATTACH=full]308747[/ATTACH]
[ATTACH=full]308748[/ATTACH]

We use position:fixed to make elements stay at a fixed part of the screen

Use this in your code

.wrapper{ position:fixed; top:0px; }

Edit: Make stackoverflow your friend. 99.9999% of my code is copied from there
[ATTACH=full]308749[/ATTACH]

Also learn to use inspect using your browser, use it on sites you like to show you how they did it using css or javascript .

How do I click OK through Javascript in this alert box? Inspect element haifiki huku[ATTACH=full]308755[/ATTACH]

this is just a popup box using JS

https://www.w3schools.com/js/js_popup.asp

Thanks. How do I programaticaly click it through JS?

freecodecamp.org…itakusaidia sana

Thanks. But nikiimpliment hiyo the navigation bar remains at the top and becomes unclickable. i cannot open the pages link on the navigation bar menu
[ATTACH=full]308786[/ATTACH]

Jaribu kuongezeaz-index:50;
uone kama itafanya

good step …lakini jifunze kutumia inspect element na chrome kucheza na css

Asante to all those who have helped OP. @mlipuayote additionally look at this https://devdocs.io/ you can install it on your browser to access it offline. It really helped when I was doing baby steps in HTML/CSS

Idk why you have the to have two elements with the class wrapper if you want to center both sections
you can easily wrap the whole doc
like

[CODE=css]body{ background:#ccc;}
.wrapper{background:#fff; margin: 0 auto; width:80%; padding :15px; min-height:80%; }

[/CODE]

then in the html you can have

[CODE=html]

Nairobi

[/CODE]

you can also read on grid layout and flex box

I always though mi ni guru, leo i had a frontend interview, that is when i have learnt that you always have tobe on your toes. Also make stackoverflow your friend.