MyBB Community Forums

Full Version: Collapse/Expand button not saved
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi

In one of my theme when users click on collapse/expand icon to minimize or expand forum categories it works fine but it dows not save for next visit. 
for other theme last view will be saved for users.
What is in your forumbit_depth1_cat template for that custom theme template set?
(2023-06-13, 03:38 PM)Taylor M Wrote: [ -> ]What is in your forumbit_depth1_cat template for that custom theme template set?

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<thead>
<tr>
<td class="thead{$expthead}" colspan="5">
<div class="expcolimage"><i id="cat_{$forum['fid']}_img" class="fa fa-window-minimize expander" ></i></div>
<div><strong><a href="{$forum_url}">{$forum['name']}</a></strong><br /><div class="smalltext">{$forum['description']}</div></div>
</td>
</tr>
</thead>
<tbody style="{$expdisplay}" id="cat_{$forum['fid']}_e">
<tr>
<td class="tcat" colspan="2"><span class="smalltext"><strong>{$lang->forumbit_forum}</strong></span></td>
<td id="threads" class="tcat" width="85" align="center" style="white-space: nowrap; font-size: 16px;"><span class="smalltext"><strong>{$lang->forumbit_threads}</strong></span></td>
<td id="replies" class="tcat" width="85" align="center" style="white-space: nowrap; font-size: 16px;"><span class="smalltext"><strong>{$lang->forumbit_posts}</strong></span></td>
<td id="lastpost" class="tcat" width="350" align="center"><span class="smalltext"><strong>{$lang->forumbit_lastpost}</strong></span></td>
</tr>
{$sub_forums}
</tbody>
</table>
<br />
Any update?
site url ?
(2023-07-22, 02:33 PM)PARADOX987 Wrote: [ -> ]site url ?

hi, I can not send you PM because you accept PM from buddy only, HERE is my website,
You should probably check for updated templates.

Admin CP --> Templates & Styles --> Templates --> Find Updated Templates.

Particularly your headerinclude templates. I'm not sure what version of MyBB you're using but its possible your template isn't referencing the right version for javascript files unless you're just that far behind on versions.

What you've got right now:
<script type="text/javascript" src="{$mybb->asset_url}/jscripts/jquery.js?ver=1813"></script>
<script type="text/javascript" src="{$mybb->asset_url}/jscripts/jquery.plugins.min.js?ver=1813"></script>
<script type="text/javascript" src="{$mybb->asset_url}/jscripts/general.js?ver=1817"></script>
(2023-08-27, 05:35 PM)Taylor M Wrote: [ -> ]You should probably check for updated templates.

Admin CP --> Templates & Styles --> Templates --> Find Updated Templates.

Particularly your headerinclude templates. I'm not sure what version of MyBB you're using but its possible your template isn't referencing the right version for javascript files unless you're just that far behind on versions.

What you've got right now:
<script type="text/javascript" src="{$mybb->asset_url}/jscripts/jquery.js?ver=1813"></script>
<script type="text/javascript" src="{$mybb->asset_url}/jscripts/jquery.plugins.min.js?ver=1813"></script>
<script type="text/javascript" src="{$mybb->asset_url}/jscripts/general.js?ver=1817"></script>
 I use latest version of MYBB, I replaced above codes in headerimclude but  the problem persist.
No change yet, as seen on your index page when viewing page source.
Your css references are called twice, at least that's an improvement from previously when I saw it was called three times.
Redundant, but harmless.

If you turn on template tags, it's easier to see where something is being called from.
After you're all squared away, you can disable them again.
AdminCP / Configuration / Server and Optimization Options / Output template start/end comments?

A line appears at top of your index page as text.

[attachment=46275]

Somewhere this code is in a template. If the dataLayer code is necessary for functionality, it is missing the < script > tags.
The css references can be deleted since they are already invoked.

window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-120533740-1');
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/latestposts.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/avatarep.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/global.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/extra.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/css3.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/footer.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/tooltip.min.css?t=1692824486" />
(2023-08-28, 10:46 AM)HLFadmin Wrote: [ -> ]No change yet, as seen on your index page when viewing page source.
Your css references are called twice, at least that's an improvement from previously when I saw it was called three times.
Redundant, but harmless.

If you turn on template tags, it's easier to see where something is being called from.
After you're all squared away, you can disable them again.
AdminCP / Configuration / Server and Optimization Options / Output template start/end comments?

A line appears at top of your index page as text.



Somewhere this code is in a template. If the dataLayer code is necessary for functionality, it is missing the < script > tags.
The css references can be deleted since they are already invoked.

window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-120533740-1');
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/latestposts.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/avatarep.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/global.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/extra.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/css3.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/footer.min.css?t=1692824486" />
<link type="text/css" rel="stylesheet" href="https://forum.civilea.com/cache/themes/theme98/tooltip.min.css?t=1692824486" />

thanks you for your reply, 
I fixed the top page error and I checked and saw " Output template start/end comments?"  is enable. could you please what shall I do?
Pages: 1 2