News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Forum Name in Browser Title

Started by Matthew K., February 18, 2010, 06:12:00 AM

Previous topic - Next topic

Matthew K.

Thanks for the feedback!

Eventually, not sure when but I do plan on updating all of my mods for 2.0 that should be.

smartblogz

We are eagerly waiting as I cannot install this on my forum. :D
I use 2.0

PatrickForum

Note for everybody who's using smf 2.0.1. and planning to install this forum title mod:
You have to emulate to 2.0 RC4 to use this mod, since it is not updated yet.

Instructions on how you can emulate your SMF forum (it's very easy to do), please check:
http://www.simplemachines.org/community/index.php?topic=410291.msg2859935#msg2859935
http://www.simplemachines.org/community/index.php?topic=410291.msg3212260#msg3212260

PatrickForum

#63
@labradoodle-360

The index.dutch.php file you gave me is the solution for the double forum name at the forum's homepage.
But when I use the file, Forumindex is on the left side of the forum name instead of behind the forum name.
(My settings in the admin panel are correct; all other titles on the forum are correctly set, only the homepage is not correct yet).

So let me explain:

1. First, the title of the homepage was: Geld Verdienen Op Internet Forum - Forumindex - Geld Verdienen Op Internet Forum

2. After your change of index.dutch.php it was Forumindex - Geld Verdienen Op Internet Forum. Thank you.

What I want, if possible, is only at the homepage a setting like this: Geld Verdienen Op Internet Forum - Forumindex
and on all other pages: Board Name - Geld Verdienen Op Internet Forum

If not possible, can I remove "Forumindex" from the homepage's title?
Can you let me know if this is possible? Thanks.

Link to the forum is Geld Verdienen Op Internet Forum

Matthew K.

#64
I'll re-write this mod for SMF 2.0.1 for you soon.


The next version will be "2.0"...here is what I am planning...

  • (!) SMF 2.0+ Compatibility Only.
  • (!) Source edits only, NO templates. Will work in all themes out of the box.
  • (+) Portal Compatibility for SimplePortal, and TinyPortal

Matthew K.

Forum Name in Browser Title 2.0 Released!

Quote from: ReadmeForum Name in Browser Title


Author: Labradoodle-360
Latest Version: 2.0
Compatible With SMF: 2.0.99
Dedicated To: LIM and my family



Summary

Forum Name in Browser Title allows you to put your forum name in the browser title (compatible with all Portals and all themes).

Here are the settings...

  • Forum Name in Browser Title Position: [Disabled | Before Page Title | After Page Title]
  • Separation Character - Allows you to define a character to separate the page title, from your forum name.

Written using Source edits only, so this modification will work on ALL themes.

Formerly known as "Forum Name as Prefix for Forum Title"

Installation

Package Manager should work in most cases. If you need to make any edits, the full list can be obtained from the Parse function on the right.

Useful links
Manual Installation Of Mods
How Do I Modify Files?




Link to Mod | Support Labradoodle-360's Development

madnexus

Thanks a lot for the update pal!

I will give some feedback tomorrow as soon as I try it..

Matthew K.

No problem, let me know what you think.

sAce

Hi, Thanks for the mod

I just found this problem ,

<title>Hello Everyone !!!!&nbsp-&nbspMy Forum</title>

and this gets picked up by google as well, so you can imagine this is not pretty at all.

Please Help :)

Matthew K.

Oh wow, can you say bug? Thanks for catching it. I was half asleep when I wrote that part.

Here's the fix...
./Sources/forum-name-in-browser-title/Main.php
Code (Find) Select

$separation_char = '&nbsp';
if (!empty($modSettings['page_title_separation_char']))
$separation_char .= trim(un_htmlspecialchars($modSettings['page_title_separation_char']));
else
$separation_char = '-';
$separation_char .= '&nbsp';

Code (Replace) Select

$separation_char = '&nbsp;';
if (!empty($modSettings['page_title_separation_char']))
$separation_char .= trim(un_htmlspecialchars($modSettings['page_title_separation_char']));
else
$separation_char = '-';
$separation_char .= '&nbsp;';

Matthew K.

Forum Name in Browser Title 2.0.1 (Bugfix thanks to sAce) released
Quote from: ReadmeForum Name in Browser Title


Author: Labradoodle-360
Latest Version: 2.0.1
Compatible With SMF: 2.0.99
Dedicated To: LIM and my family



Summary

Forum Name in Browser Title allows you to put your forum name in the browser title (compatible with all Portals and all themes).

Here are the settings...

  • Forum Name in Browser Title Position: [Disabled | Before Page Title | After Page Title]
  • Separation Character - Allows you to define a character to separate the page title, from your forum name.

Written using Source edits only, so this modification will work on ALL themes.

Formerly known as "Forum Name as Prefix for Forum Title"

Bugfix reported by sAce, fixed in 2.0.1

Installation

Package Manager should work in most cases. If you need to make any edits, the full list can be obtained from the Parse function on the right.

Useful links
Manual Installation Of Mods
How Do I Modify Files?




Link to Mod | Support Labradoodle-360's Development

sAce


Matthew K.


sAce

Hmm.. you sure fixed that one, but it didnt solve my problem. still exists.

Mstcool

Can u make it compatible with 2.0.2

Matthew K.


Mstcool

well i think some of the files dont work
because i think it said tht we strongly recommend not to install because of something
sorry i dont remember

Matthew K.

You'll need more details than that for me to be able to help you.

Mstcool


OCJ

#79
Works fine with 2.0.2 and Simple Portal 2.3.4 but I get a lot of errors in the log:

File: Forum-Name-in-Browser-Title-2.0.1.zip

Settings:
Forum Name in Browser Title: Before page title
Separate Page Title With: -

Also use meta tags mod but nothing in there relating to browser title....




   
May be more than these....


/index.php?action=forum
Undefined offset: 1

Sources/forum-name-in-browser-title/Main.php
Line 41: return $context['page_title_html_safe'] = $pieces[0] . $separation_char . $pieces[1];



/index.php?action=dlattach;topic=1521.0;attach=1095;image
Undefined index: forum_name_html_safe
==>103:    ', $txt['login_below'], ' <a href="', $scripturl, '?action=register">', $txt['register_an_account'], '</a> ', sprintf($txt['login_with_forum'], $context['forum_name_html_safe']), '

Advertisement: