Jump to the post that solved this thread.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Solved: 2 Months, 3 Days ago Change Subforum Tab Background
#1
Solved: 2 Months, 3 Days ago
Hello guys!
How to change subforum tab background one by one?

[Image: subforum.png]
Reply
#2
Solved: 2 Months, 3 Days ago
(08-11-2018, 11:39 PM)_BcY Wrote: Hello guys!
How to change subforum tab background one by one?

https://i.hizliresim.com/4zVLMp.png

Access to the image has been denied.

So... we can't see what you are wanting.
I'm Serpius and You're Not
[Image: 5M7sb0n.png?1]
Reply
#3
Solved: 2 Months, 3 Days ago
Updated the link.
Reply
#4
Solved: 2 Months, 3 Days ago
(08-12-2018, 08:27 PM)_BcY Wrote: Updated the link.

Honestly, I am not certain what you are asking for. Not following this part "one by one". 

Can you clarify this a bit?
I'm Serpius and You're Not
[Image: 5M7sb0n.png?1]
Reply
#5
Solved: 2 Months, 3 Days ago
Admin CP --> Templates & Styles --> Themes --> Default --> global.css

Find .thead and then edit the background color.
> SELECT finger FROM hand WHERE id='3'
Reply
#6
Solved: 2 Months, 3 Days ago
I think he wants to change the color of that thead for each specific forum, not just globally.
Reply
#7
Solved: 2 Months, 3 Days ago
(08-13-2018, 03:08 AM)Thanos Wrote: I think he wants to change the color of that thead for each specific forum, not just globally.

Yea, I think you might be right.
I'm Serpius and You're Not
[Image: 5M7sb0n.png?1]
Reply
#8
Solved: 2 Months, 3 Days ago
Not tested but something like this should work:

Open 'forumdisplay_threadlist' template and locate this line:

PHP Code:
<td class="thead" colspan="{$colspan}"

Change it to:

PHP Code:
<td class="thead" colspan="{$colspan}style="background: url('{$mybb->asset_url}/bg_{$fid}.png') repeat"

Now upload the background image files, named after your forum id ('bg_2.png', 'bg_7.png' etc) in your image folder.

You need to upload single image for each forum separately with the outlined naming pattern.
Disclaimer: Don't be misguided looking at my usergroup and assume whatever I say is official. When I speak in community I am just a member with personal opinions.
Reply
#9
Solved: 2 Months, 3 Days ago
(08-13-2018, 12:19 PM)effone Wrote: Not tested but something like this should work:

Open 'forumdisplay_threadlist' template and locate this line:

PHP Code:
<td class="thead" colspan="{$colspan}"

Change it to:

PHP Code:
<td class="thead" colspan="{$colspan}style="background: url('{$mybb->asset_url}/bg_{$thread['tid']}.png') repeat"

Now upload the background image files, named after your forum id ('bg_2.png', 'bg_7.png' etc) in your image folder.

You need to upload single image for each forum separately with the outlined naming pattern.


Correct if I'm wrong, but isn't $thread['tid'] the thread_id? I think they would want $thread['fid'] for forum_id; I can't imagine creating a background image per thread. Personally, I would have added a new CSS class based on the forum_id instead of directly referencing an image, which could result in a lot of 404 Not Found messages in your server log.
Reply
#10
Solved: 2 Months, 3 Days ago
Yes you are correct. Just typed it on the fly using mobile.
Good spot.

May be its $foruminfo['fid'] or just $fid to be more correct (both works).

CSS class usage is the right choice if you know the number of forums you have and remember to add more classes whenever you add a forum. To avoid this remember thing I have suggested inline.
Disclaimer: Don't be misguided looking at my usergroup and assume whatever I say is official. When I speak in community I am just a member with personal opinions.
Reply
Jump to the post that solved this thread.


Forum Jump:


Users browsing this thread: 2 Guest(s)