Fixed horizontal line at top of page

For support and discussion related to templates and themes in phpBB 3.3.
CD130
Registered User
Posts: 116
Joined: Thu Nov 13, 2014 2:09 pm

Fixed horizontal line at top of page

Post by CD130 »

Hi,

I used this code for my board to get it with a horizontal line at the top of each page:
viewtopic.php?t=2390371

Does anyone know the code how the line can remain permanently (fixed) at the top of the page? Also while scrolling.

Thanks :)
User avatar
SpIdErPiGgY
Registered User
Posts: 243
Joined: Sun May 02, 2021 2:11 pm
Location: Erpe-Mere, Aalst, BE
Name: Andy Dm

Re: Fixed horizontal line at top of page

Post by SpIdErPiGgY »

I guess in the common.css code, add:
position:fixed;
phpBB NL Extension translations, also on request.
--> Click Here: Myarea51secrets.com <--
User avatar
halil16
Registered User
Posts: 1365
Joined: Fri Jul 24, 2020 11:30 pm
Location: Turkiye
Name: Halil

Re: Fixed horizontal line at top of page

Post by halil16 »

No, not like that.

Add something like this in the header file (Can be inserted in the first line inside <body>) :

Code: Select all

<div class="iambatman"></div>
then a css like this should do the trick:

Code: Select all

.iambatman {
    display: block;
    position: fixed;
    top: 0;
    height: 3px;
    width: 100%;
    background: #b20000;
    z-index: 9999999;
}
Buy me a coffee
Hire me for your phpBB board.
Introducing Mobile Upgrade! Make your phpBB board like an app!
O BeldeThatTowns*for sale*
"The day we will need ideas more than possessions, we will find the secret to true wealth." - Peyami Safa
CD130
Registered User
Posts: 116
Joined: Thu Nov 13, 2014 2:09 pm

Re: Fixed horizontal line at top of page

Post by CD130 »

Yes :) It works!! You are amazing, thanks!!
User avatar
halil16
Registered User
Posts: 1365
Joined: Fri Jul 24, 2020 11:30 pm
Location: Turkiye
Name: Halil

Re: Fixed horizontal line at top of page

Post by halil16 »

You're welcome.
Buy me a coffee
Hire me for your phpBB board.
Introducing Mobile Upgrade! Make your phpBB board like an app!
O BeldeThatTowns*for sale*
"The day we will need ideas more than possessions, we will find the secret to true wealth." - Peyami Safa

Return to “[3.3.x] Styles Support & Discussion”