MyBB Community Forums

Full Version: Sidebar on portal
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have latest threads sidebar on my index with hide/show option. I want to have same function on my portal to show or hide latest threads table with a sidebar but I couldn't do. When I copy javascript and sidebar codes of index, last threads tables dissappears both on index and portal. So how can I do that?


index Template:
<div class="sidebar" style="float: right; width: 250px;">

<script type="text/javascript">
jQuery(function(){
jQuery(".latestthreads").load("{$mybb->settings['bburl']}/portal.php .latestthreads_portal");
});
</script>

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<tr>
<td class="thead">
<div class="expcolimage"><img src="{$theme['imgdir']}/collapse.gif" id="ths_img" class="expander" alt="[-]" title="[-]" /></div>
<strong>
Son Yorumlar
</strong>
</td>
</tr>
<tr>
<td class="trow3" style="{$collapsed['ths_e']}" id="ths_e">

<div class="latestthreads float_left">
</div>

</td>
</tr>
</table>

</div>

<div class="forums" style="float: left; width: 810px;">
{$forums}
</div>

Portal_lastthreads template:

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<tr>
<td class="thead"><strong>{$lang->latest_threads}</strong></td>
</tr>
{$threadlist}
</table>
<br />


Link: http://dontstarveturkiye.com/forum/index.php
Pls help