Advertisement:

Author Topic: How can I change the header image per board id?  (Read 2431 times)

Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,298
  • Master of BBC Abuse
Re: How can I change the header image per board id?
« Reply #20 on: June 29, 2020, 11:51:44 PM »
Good. Now (or actually a tad later) I'll head over to GitHub (may its name be cursed forever) and see if anyone has tested body classes as styling parents with Chrome on iOS (I bet nobody has).

Offline drewactual

  • Sr. Member
  • ****
  • Posts: 857
    • College Football Fan Site CFB51
Re: How can I change the header image per board id?
« Reply #21 on: July 02, 2020, 08:12:16 AM »
question: I do this same thing but using URL's to control it... what is the advantage to using $boardid? what is the disadvantage to using URL's? 

Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,298
  • Master of BBC Abuse
Re: How can I change the header image per board id?
« Reply #22 on: July 02, 2020, 09:43:54 AM »
Doesn't really matter much, I suppose. Board ID is just a handy and tidy thing to call, but there's nothing really wrong with using URL's as far as I know.

When this code was originally requested some years back people were asking for the ability to style by board, so board ID just seemed like the natural way of doing it. If you use the URL you have to include the board ID as part of that anyway, so all the rest is just extra stuff to throw into your logic.

Offline drewactual

  • Sr. Member
  • ****
  • Posts: 857
    • College Football Fan Site CFB51
Re: How can I change the header image per board id?
« Reply #23 on: July 02, 2020, 10:47:40 AM »
fair enough- thanks for the response. 


Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,298
  • Master of BBC Abuse
Re: How can I change the header image per board id?
« Reply #24 on: July 02, 2020, 06:46:11 PM »
After posting that I did think of one advantage, depending on what you want to do. If you want to keep the custom board banner for all topics inside that board (ie: when viewing Display.template) then the current board stuff in Sources keeps track of that for you, so that makes board ID the easy way to get what you want.

If you want to change the banner according to topic, then a URL is probably as good for all practical purposes. But at the time this code was written it just seemed to make sense to have one chunk that did all possible body tag classes, and use the actions, board ID's, topics ID's, etc to do it.

Offline drewactual

  • Sr. Member
  • ****
  • Posts: 857
    • College Football Fan Site CFB51
Re: How can I change the header image per board id?
« Reply #25 on: July 02, 2020, 10:36:50 PM »
i run with an include file- and have different styling for each and every board... some with a header, some without... the main page with a random image (one of several hundred)... different functions.... different metatags and different OG: and twitter cards.. i kind of took the concept to an extreme... i use the same device to interject styled WP articles or not... it's a dang handy tool.   i guess i could have used $board, and it still 'kinda' does, but the css issue doesn't exist in this manner of doing it. 

problem: i understand php8 (when we're finally forced there) changes the functions or antiquates it, so... i'll be re-drafting.... and i may use $board... which puts me in the same boat as this thread here and is something to think about before that day comes.... have a plan, right?

Offline Seedorfbiggy

  • Newbie
  • *
  • Posts: 1
Logo image URL
« Reply #26 on: July 07, 2020, 10:00:18 AM »
Please how can I set Logo image URL to show my desire logo above :(

Offline shadav

  • Full Member
  • ***
  • Posts: 419
  • Gender: Female
    • Ask The Muslims: A Place To Ask Honest Questions and Receive Respectful Answers
Re: Logo image URL
« Reply #27 on: July 07, 2020, 11:53:33 AM »
Please how can I set Logo image URL to show my desire logo above :(

um...that doesn't actually have anything to do with the topic of this thread....it'd be best to either search or create your own post ;)

without knowing exactly what you mean....or what template you are using....or what version of smf you are using.....have you gone into your admin?
in admin under configurations and then current theme
you will find
Logo image URL:
(leave blank to show forum name or default logo.)

if that is not what you are wanting then you will need to be a bit more specific and within your own thread not randomly asking in an unrelated thread