XF 2.1 Change forum <title> that appears in Google

didieregear

New member
Hello,

I'm new to Xenforo and I just installed it: https://www.egearforum.com

In the Xenforo dashboard I gave it the name "eGear Forum" (see attachment). This is fine for normal posts, because then the title become: post title | eGear Forum.

For the index page I want to change the title however. I want it to be "Forum over elektrisch rijden | eGear Forum". How do I get this between the <title></title> tags on my index page?
 

Attachments

  • Screen Shot 2019-06-12 at 19.43.56.webp
    Screen Shot 2019-06-12 at 19.43.56.webp
    14.2 KB · Views: 6
Edit the PAGE_CONTAINER template and replace the title code with:

Rich (BB code):
<xf:if is="$template == 'forum_list'">
        <title>CUSTOM TITLE</title>
    <xf:else />
        <title><xf:title formatter="%s | %s" fallback="{$xf.options.boardTitle}" page="{$pageNumber}" /></title>
    </xf:if>

Replacing CUSTOM TITLE with your preferred site title.
 
Edit the PAGE_CONTAINER template and replace the title code with:

Rich (BB code):
<xf:if is="$template == 'forum_list'">
        <title>CUSTOM TITLE</title>
    <xf:else />
        <title><xf:title formatter="%s | %s" fallback="{$xf.options.boardTitle}" page="{$pageNumber}" /></title>
    </xf:if>

Replacing CUSTOM TITLE with your preferred site title.

That worked like a charm. You are a hero!
 
Back
Top Bottom