MyBBHacks.com Plugins for  MyBB
display bug from index to gallery page when using Unread Posts plugin - Printable Version

+- MyBBHacks.com Plugins for MyBB (https://www.mybbhacks.com)
+-- Forum: ezGallery Pro for MyBB (https://www.mybbhacks.com/forumdisplay.php?fid=8)
+--- Forum: Support (https://www.mybbhacks.com/forumdisplay.php?fid=10)
+--- Thread: display bug from index to gallery page when using Unread Posts plugin (/showthread.php?tid=2826)



display bug from index to gallery page when using Unread Posts plugin - zoldos - 11-01-2016

I know I'm not Pro (yet), but I found a small bug.  I use the "Unread Posts" plugin, and this link disappears when I view the Gallery, then re-appears on every other page.  Please see attached screenshots.  Thanks!


RE: display bug from index to gallery page when using Unread Posts plugin - MyBBHacks - 11-01-2016

Probably because that plugin's language file is no longer loaded?That would be my guess.


RE: display bug from index to gallery page when using Unread Posts plugin - zoldos - 11-01-2016

Yeah makes sense. I'll mess around with the templates, see what I can do. Thanks! Smile


RE: display bug from index to gallery page when using Unread Posts plugin - hkkp - 05-26-2018

(11-01-2016, 09:32 AM)MyBBHacks Wrote: Probably because that plugin's language file is no longer loaded?That would be my guess.

and how do I load them? asked stupid?


RE: display bug from index to gallery page when using Unread Posts plugin - hkkp - 05-27-2018

i have this in the gallery.lib.php:


PHP Code:
function gallery_header()
{
   global $headerinclude$context$header$templates$lang;
   $lang->load("unreadPosts");
   eval("\$unreadPosts .= \"" $templates->get("unreadPosts_link") . "\";");
   $header str_replace('<!-- UNREADPOSTS_LINK -->'$unreadPosts$header);

    if (isset($context['linktree']))
    foreach($context['linktree'] as $linktree)
    {
        add_breadcrumb($linktree['name'], $linktree['url']);
    }

    echo parse_page('<html>
<head>
<title>' 
$context['page_title'] .'</title>
$headerinclude '
$context['html_headers'] . '
</head>
<body>
$header);





this works. 

but now the counter for the unread messages is missing. how does it work?


RE: display bug from index to gallery page when using Unread Posts plugin - MyBBHacks - 05-27-2018

It's a little tricky. For porting reasons I did not use MyBB templates when I made the plugin. You might ave to include the code for counter.