News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

How to place a general message above all forums

Started by sbartelski, March 17, 2021, 02:35:47 PM

Previous topic - Next topic

sbartelski

I have looked everywhere, but cannot find a way to place a text in the forum header. Can someone point me in the right direction, please?

What I would like to do is have a message like "Merry Christmas" or "We are experiencing some technical issues, but the forum is still open. Be aware that you may need to.....".  The latter is very current for me right now

Stefan
Stefan Bartelski
Webmaster for the Cadillac LaSalle Discussion forums

Kindred

that's generally what the NEWS section is for... :)
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

shadav

 :laugh: that's what I was going to say....use the news system and in the current theme settings allow news in header

but otherwise would need to know where you want it placed (but then each time you want to change it, you'll have to edit the actual files)

sbartelski

Thanks for those replies, they look like they will give the desired result. I will try it out shortly and then post back

Stefan
Stefan Bartelski
Webmaster for the Cadillac LaSalle Discussion forums

sbartelski

Thanks to everyone for their help, I do have the desired solution
Stefan Bartelski
Webmaster for the Cadillac LaSalle Discussion forums

efk

Can it be done with portal mod when using to display Everywhere? If I'm right the message from the News section will show only to Forum page with boards.
News section is coming with jumping boards problem if you use few messages, so after some time text message will change if there is a difference on text length so result will be often blind clicking on wrong boards because it will jump all the time like Facebook news page does, updating all the time with every single post, or infinite loading for older computers and moving focus all the time.

Ninja ZX-10RR

Quote from: efk on March 17, 2021, 11:12:40 PM
Can it be done with portal mod when using to display Everywhere? If I'm right the message from the News section will show only to Forum page with boards.
News section is coming with jumping boards problem if you use few messages, so after some time text message will change if there is a difference on text length so result will be often blind clicking on wrong boards because it will jump all the time like Facebook news page does, updating all the time with every single post, or infinite loading for older computers and moving focus all the time.
A bit hard to understand but if you have different heights for your news items I would suggest using [html][/html] tags in the news admin input area and from there you can add something along the lines of...
[html]<p style="height: 2em; display: flex; align-items: center; justify-content: center;">Your news here</p>[/html]
Basically give it some height so that the shorter item will have more space as long as you don't go overkill with the longer one. Trial and error a bit.
This will also turn the news item into flex, it's needed otherwise you can't vertically align text inside an inline element...

An alternative solution would be:
[html]<p style="height: 2em; display: inline-block; margin: auto;">Your news here</p>[/html]
But this won't vertically align them.

Tweak the 2em as needed, of course :)
And yes, we could get a perfect result with css by adding a :before empty element to the inline element but I don't have time to elaborate on that.
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Kindred

or do it properly in CSS rather than inline inside the news....
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

sbartelski

Thanks again for these further suggestions. I actually found enough in using BBCode tags (, ) to "jazz" up my message. And since the major reason for my News message has been resolved, the BBC tags are enough.

Luckily, as CSS is beyond my capabilities right now and I have enough on plate without adding learning CSS ;-)

Stefan
Stefan Bartelski
Webmaster for the Cadillac LaSalle Discussion forums

Sir Osis of Liver

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Advertisement: