Skip to main content
Topic: Displaying the words "Today" and “Yesterday” in bold lettering (Read 1985 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Displaying the words "Today" and “Yesterday” in bold lettering

Hello!

How can I display the words "Today" and “Yesterday” in bold lettering in the column of the recent posts on the board index?
I tried it on this way in the index.english.php:

Code: [Select]
$txt['today'] = '<strong>today</strong> at %1$s';
$txt['yesterday'] = '<strong>yesterday</strong> at %1$s';

Indeed it worked perfect but now with the addon 'Users Online Today' there’s a problem. When I place the mouse pointer over a user name, the time of the last activity is displayed including the strong tags:

<strong>Today</strong> at 05:40 PM

How can I display the words "Today" and “Yesterday” in bold lettering without causing an effect on the 'Users Online Today' time display?

Re: Displaying the words "Today" and “Yesterday” in bold lettering

Reply #1

That's the "correct" way, if the addon is the the problem, change:
Code: [Select]
$title = !empty($user['last_login']) ? 'title="' . standardTime($user['last_login']) . '" ' : '';
to:
Code: [Select]
$title = !empty($user['last_login']) ? 'title="' . strip_tags(standardTime($user['last_login'])) . '" ' : '';
in OnlineToday.class.php. ;)
Bugs creator.
Features destroyer.
Template killer.

Re: Displaying the words "Today" and “Yesterday” in bold lettering

Reply #2


Thanks, now all is perfect. :)