Custom Page Title
-
@a_5mith They do on chrome I think its bugged on safari.
Browser title bug · Issue #2854 · NodeBB/NodeBB
There´s some bugs on browser title update. 1- On safari on mac, if you enter home or categories will go just fine, but if you enter on a topic the browser title goes back to default after a second. ( default = first browser title that wa...
GitHub (github.com)
-
for that feature. Would be really great if you could move the order for example. So this here could look like NodeBB | Custom Page Title instead of Custom Page Title | NodeBB
-
@psychobunny Any news on this? I don't want "Home" in there as well. Thanks!
-
I must have missed that setting also?
Site Title and Title Layout
Should i set this " {pageTitle} | {browserTitle}" to {browserTitle} ??? Or how should it be used?
I want to keep pageTitle on all the other pages and change the home part on the startpage!
Any other vars except
{pageTitle}
{browserTitle} -
I guess we will need to stick to Home if we want pagename | *
-
Hi. I`d try
if (req.path === '/api/' || req.path === '/') { meta.config.browserTitle = '{browserTitle}'; config.browserTitle = meta.config.browserTitle || meta.config.title; meta.config.titleLayout = '{browserTitle}'; config.titleLayout = (meta.config.titleLayout || '{browserTitle}').replace(/{/g, '{').replace(/}/g, '}'); }
in src/controllers/api.js where meta configs defined - but it doesn't work( where I can change core files to modify "Home | " from index page? than i'd try
if (req.path === '/api/' || req.path === '/') { config.titleLayout = (meta.config.titleLayout || '{browserTitle}').replace(/{/g, '{').replace(/}/g, '}') .replace(/|/g, '').replace(/|/g, '').replace(/\|/g, ''); } else { config.titleLayout = (meta.config.titleLayout || '{pageTitle} | {browserTitle}').replace(/{/g, '{').replace(/}/g, '}'); }
after "home": " " in pages.json but I had only "| NodeBB"
also I saw https://github.com/julianlam/nodebb-plugin-canned-responses/blob/master/library.js and your hook addTitles but I dont understand how can i modify <title> on main page with this hook after I choose it with titleMatch = /^/api/$/ or titleMatch = /^/$/
thanks. -