Provatoo.NET

Diario di bordo di una sviluppatrice

MyBB

Crea una sidebar a scomparsa per MyBB

Dopo un grade topic su Cionfs.it siamo arrivati alla conclusione su come fare una barra laterale a scomparsa.

Prima di tutto, è necessario scaricare i file allegati e caricarli sul tuo forum. Le due immagini vanno nella cartella immagini del tuo forum. I due file javascript andare nella cartella jscripts, che trovi nel file zip.

Entra nel PDA>>Temi&Template>>Template>>TuoTema>> Index Templates>>index
e sostituisci tutto il contenuto con il codice riportato qui sotto.

<html>
<head>
<title>{$mybb->settings['bbname']}</title>
{$headerinclude}
<script type="text/javascript">
<!--
lang.no_new_posts = "{$lang->no_new_posts}";
lang.click_mark_read = "{$lang->click_mark_read}";
// -->
</script>
<style type="text/css">
.buttons {
background: url(images/arrowright.png) no-repeat;
width: 16px;
height: 16px;
display: block;
cursor: pointer;
}

.clickedbuttons {
background: url(images/arrowleft.png) no-repeat;
width: 16px;
height: 16px;
display: block;
cursor: pointer;
}
</style>
</head>
<body>
{$header}
<a style="float: right;"></a>
<a style="float: right;"></a>
<br />
<div style="float: right;width: 19%;">
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}">
<tr>
<td><strong>
Latest News
</strong></td>
</tr>
<tr>
<td>
You can put some news stuff here
</td>
</tr>
</table>
</div>
<div style="float: left;width: 80%;">
{$forums}
</div>
<br />
{$boardstats}

<dl>
<dt><img src="{$theme['imgdir']}/on.gif" alt="{$lang->new_posts}" title="{$lang->new_posts}" style="vertical-align: middle; padding-bottom: 4px;" /></dt>
<dd>{$lang->new_posts}</dd>

<dt><img src="{$theme['imgdir']}/off.gif" alt="{$lang->no_new_posts}" title="{$lang->no_new_posts}" style="vertical-align: middle; padding-bottom: 4px;" /></dt>
<dd>{$lang->no_new_posts}</dd>

<dt><img src="{$theme['imgdir']}/offlock.gif" alt="{$lang->forum_locked}" title="{$lang->forum_locked}" style="vertical-align: middle;" /></dt>
<dd>{$lang->forum_locked}</dd>
</dl>
<br style="clear: both" />
{$footer}
</body>
</html>

 

Salva e chiudi. Apri Ungruped Templates>>headerinclude Trova:

{$stylesheets}

Prima di questo aggiunggi:

<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
 <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/jquery-ui.min.js"></script>
 <script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/jquery.cookie.js"></script>
 <script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/sidebar.js"></script>

Per ogni problema chiedi pure!

Provatoo.NET

Piccola imprenditrice, ma solo di statura :D