Skip to content
← Back to Community
HTML HELP: how to i enter a banner to the top of my web page?
Profile icon
AngelTorres4

how to i enter a banner to the top of my web page?

Answered by a5rocks [earned 5 cycles]
View Answer
Voters
Profile icon
chloe-wuwu
Profile icon
Crosshairs1
Profile icon
InayaAlminawi
Profile icon
AaronAnyaegbu
Profile icon
AngelTorres4
Comments
hotnewtop
Profile icon
a5rocks

You can use a <div> element and make either an id or a class called banner. Then in your main.css file, just add something like this: (assuming you are using an id as banner)

#banner { background-color: #ffffff; width: 100%; /* If you want it to stay at the top: */ top: 0; position: fixed; }

at least... I think that will work

Profile icon
katyadee

Hey there! Make sure you're always providing enough context to your posts so our community can better help you.

Profile icon
Geocube101

You can also use the <nav> element, which creates a bar at the top of the page