XF 2.0 How To Add Forum Tagline & Disable Font BB Codes

Car_Freak

Member
Hi.

I’ve been trying to figure out solution for these issues from a while now but no luck.

Forum Tagline

How to add a tagline to forum name in browser tab for forum list view (homepage) only?

Example: Forum Name – Tagline

I was previously suggested to edit Page_Container template but it didn’t work and instead messed up my site.

Disabling Font Options

I’d like to permanently disable the following options in post editor toolbar until we upgrade to XenForo 2.1.

Text Color. Font Family. Font Size.

Additionally, I’ve a custom BB code Justify icon. How do I add it in Alignment list in Post Editor?

Any help will be appreciated.

Thanks
 
I’m still looking for a method to add forum tagline. Can someone who has done so help out?

The second issue (disabling BB codes): I’ve achieved this through “Remove Editor Buttons” add-on.

Unfortunately, it also disables Alignment, Indent and Outdent options. How to comment out those options in that plugin?
 
To change the title of a particular page, you can put the title you want inside <xf:title> tags. In this case, it sounds like the forum_list template. Note that there is a "standard" title appended to the final title tag via the PAGE_CONTAINER template, and that is used for all pages. It'd be more complex to change that for a specific case.

In terms of your add-on question, you'd have to direct that to the add-on thread.
 
Can you show how you made the edit to forum_list and what didn't change as you expected?

I added the <xf:title> tag to the template and the <title> tag of the output changed (and can be seen in the browser tab). The <h1> on the page is still as it was, but that is what I'd expect given that there's a <xf:h1> tag in the template (and you specifically mentioned changing the browser tab title).
 
Hi @Mike ,

Following is what I did in the “forum_list” template.

The lines 1-4 have this text:
Code:
<xf:h1>{$xf.options.boardTitle}</xf:h1>
<xf:if is="{$xf.options.forumsDefaultPage} != 'forums'">
    <xf:title>{{ phrase('forum_list') }}</xf:title>
</xf:if>
I replaced it with this text:
Code:
<xf:h1>{$xf.options.boardTitle}</xf:h1>
<xf:if is="{$xf.options.forumsDefaultPage} != 'forums'">
    <xf:title>Custom Tagline</xf:title>
</xf:if>
This didn’t make any difference whatsoever.
 
Ahh. I was referring to adding a new <xf:title> tag. You'll note that the existing one is within <xf:if> tags and thus likely isn't being applied here.

You can make the customization below those lines.
 
Ahh. I was referring to adding a new <xf:title> tag. You'll note that the existing one is within <xf:if> tags and thus likely isn't being applied here.

You can make the customization below those lines.
Hi @Mike

Thanks. This helped me to an extent. I added the following on 5th line right below the code quoted in previous post.
Code:
<xf:title>Custom Tagline</xf:title>

However, it's showing the title in browser tab as follows:
Code:
Custom Tagline | Forum Name
instead of...
Code:
Forum Name | Custom Tagline
How do I accomplish that?
 
That's what I was referring to with this:

Note that there is a "standard" title appended to the final title tag via the PAGE_CONTAINER template, and that is used for all pages. It'd be more complex to change that for a specific case.

We always append the board title to the page-specific title tag (unless there isn't one, which is the default in this situation). You would need to change how that logic works in the PAGE_CONTAINER template, likely just making the <title> tag totally custom for this template, using something like:

Code:
<xf:if is="$template == 'forum_list'">
<title>New title you want</title>
<xf:else />
[existing <title> tag in the PAGE_CONTAINER template here]
</xf:if>
 
Top Bottom