News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

how to add side bar to themes ?

Started by Egg, April 18, 2004, 02:35:13 PM

Previous topic - Next topic

Egg

would like details on how to add side bar to forums.

not to main index page, but to the forums them sleves.

what I intend to do is to have different themes for certain boards, and have different content in their respective side bars..

is there an easy code or me to use?

thanks

Tomer

You must edit the files of the boards you want to change and make everyone a different theme and in board settings choose which theme for each board.

As for the sidebar itself, it all depends how you want to do it, do you want a new frame or not?

Owdy

#2
Quote from: Lamper on April 18, 2004, 03:03:59 PM
You must edit the files of the boards you want to change and make everyone a different theme and in board settings choose which theme for each board.
Some details, uh...

Lamper. Frames are evil. You dont need any frames.  Just simple table in index.template.php... Look my site for example
Former Lead Support Specialist

Tarvitsetko apua SMF foorumisi kanssa? Otan työtehtäviä vastaan, lue:http://www.simplemachines.org/community/index.php?topic=375918.0

Egg

jsut a simple table was what I ahd before, the top bar witht eh logo stayed the normal size, then under that and to the left of the board table was a bar 90 wide I think it was.

Tomer

Quote from: Owdy on April 18, 2004, 03:16:34 PM
Quote from: Lamper on April 18, 2004, 03:03:59 PM
You must edit the files of the boards you want to change and make everyone a different theme and in board settings choose which theme for each board.
Some details, uh...

Lamper. Frames are evil. You dont need any frames.  Just simple table in index.template.php... Look my site for example

I was asking if he wanted tables, I cant choose for him.

I would think just add something like this code in the palces you want a sidebar...


<body>

<table border="1" width="15%" height="492">
  <tr>
    <td width="100%" height="19">
      <p align="center">Navigation</td>
  </tr>
  <tr>
    <td width="100%" height="19"></td>
  </tr>
  <tr>
    <td width="100%" height="19"></td>
  </tr>
  <tr>
    <td width="100%" height="411"></td>
  </tr>
</table>

</body>


Just cooked that up now. Hope it helps.

Owdy

Quote from: Lamper on April 18, 2004, 03:47:31 PM
<body>

<table border="1" width="15%" height="492">
  <tr>
    <td width="100%" height="19">
      <p align="center">Navigation</td>
  </tr>
  <tr>
    <td width="100%" height="19"></td>
  </tr>
  <tr>
    <td width="100%" height="19"></td>
  </tr>
  <tr>
    <td width="100%" height="411"></td>
  </tr>
</table>

</body>

Just cooked that up now. Hope it helps.
That aint gonna work... Lamper, your sig says you are theme builder. Can i see at least ONE of your themes? Because if you build those same way you advise people... No offence man, but you gotta think where your limits are... Helping people is nice, kissing butts aint ;)
Former Lead Support Specialist

Tarvitsetko apua SMF foorumisi kanssa? Otan työtehtäviä vastaan, lue:http://www.simplemachines.org/community/index.php?topic=375918.0

Acf

egg do you mean cell next to every board? The messageindex.php is where everyboard is controlled. At the moment you cannot make theme per board.

themes based off other themes is planned. http://www.simplemachines.org/community/index.php?topic=239.0

But you can make whole different themes. And give every board the theme you like from that different theme.
Sigh...

Tomer

Quote from: (Acf) on April 18, 2004, 04:05:36 PM
egg do you mean cell next to every board? The messageindex.php is where everyboard is controlled. At the moment you cannot make theme per board.

themes based off other themes is planned. http://www.simplemachines.org/community/index.php?topic=239.0

But you can make whole different themes. And give every board the theme you like from that different theme.

Yeah thats what I suggested in the first place.

Egg

Quote from: (Acf) on April 18, 2004, 04:05:36 PM
egg do you mean cell next to every board? The messageindex.php is where everyboard is controlled. At the moment you cannot make theme per board.

themes based off other themes is planned. http://www.simplemachines.org/community/index.php?topic=239.0

But you can make whole different themes. And give every board the theme you like from that different theme.

yup. thats what I have at the moment.. totally different themes turned on in different boards..

just need the code for adding a simple left sidebar, via tables, not flash, to each of these themes.. maybe not even all of them... depends on the forum...

thanks

Owdy

Do you mean like in my forum? ( www.hoitajat.net/foorumi )

In simple way its just like this:

<table>

<tr >
       <td width="10%">Navigation</td>
       <td width="90%">Main content/forum</td>
</tr>
</table>
Former Lead Support Specialist

Tarvitsetko apua SMF foorumisi kanssa? Otan työtehtäviä vastaan, lue:http://www.simplemachines.org/community/index.php?topic=375918.0

Egg

cant seem to get to your site  ???

Unknown Host

--------------------------------------------------------------------------------
Description: Unable to locate the server named "www.hoitajat.net" --- the server does not have a DNS entry. Perhaps there is a misspelling in the server name, or the server no longer exists. Double-check the name and try again.


where would I put the code to check it out on a test theme??
thanks Owdy

Egg

Owdy

#11
Quote from: Egg on April 18, 2004, 04:50:37 PM
cant seem to get to your site  ???
Really?  :o I wonder what is wrong. Try http://www.hoitajat.net/foorumi/index.php

Quote from: Egg on April 18, 2004, 04:50:37 PM
where would I put the code to check it out on a test theme??
I have done it in index.template.php , that way that side bar is in every page in forum
Former Lead Support Specialist

Tarvitsetko apua SMF foorumisi kanssa? Otan työtehtäviä vastaan, lue:http://www.simplemachines.org/community/index.php?topic=375918.0

Acf

Quote from: Owdy on April 18, 2004, 04:53:07 PM
Quote from: Egg on April 18, 2004, 04:50:37 PM
cant seem to get to your site  ???
Really?  :o I wonder what is wrong. Try http://www.hoitajat.net/foorumi/index.php

Quote from: Egg on April 18, 2004, 04:50:37 PM
where would I put the code to check it out on a test theme??
I have done it in index.template.php , that way that side bar is in every page in forum

But he wands to add them to everyboard with a difrend content. the only way to do that is the messageindex.php. If he wanted it to be the same on every board he could use index.template.php
Sigh...

[Unknown]

You can use $context['current_board'].

-[Unknown]

Acf

Quote from: [Unknown] on April 19, 2004, 03:10:54 AM
You can use $context['current_board'].

-[Unknown]

What does that do? how does it do that?
Sigh...

Egg

NOOooo!!

Owdy, put that code back!!!

that was exactly waht I wanted!!!

different forums run different themes... logos etc... so the themes can all have a side bar.. except the main one..

simple ;)

Owdy

Quote from: Egg on April 19, 2004, 04:53:42 AM
NOOooo!!

Owdy, put that code back!!!
It still there. Did you acces to my site?
Former Lead Support Specialist

Tarvitsetko apua SMF foorumisi kanssa? Otan työtehtäviä vastaan, lue:http://www.simplemachines.org/community/index.php?topic=375918.0

Egg

ahhh

there it is.. I saw the post underneath it that saaid "edited by" and no code!! ooops!

yep, can access site through the second link you gave.

thats exaclty what I need..

I'll sort it on my site and give a link..

thanks

Egg

Zippo

Quote from: Owdy on April 18, 2004, 04:23:16 PM
Do you mean like in my forum? ( www.hoitajat.net/foorumi )

In simple way its just like this:

<table>

<tr >
       <td width="10%">Navigation</td>
       <td width="90%">Main content/forum</td>
</tr>
</table>


Where exactly in index.template.php Owdy did you place the code to get your sidebar please?

Owdy

#19
In classic theme index.template.php
find:
<table cellspacing="0" cellpadding="10" border="0" align="center" width="95%" class="tborder">
<tr></td><td valign="top" bgcolor="#ffffff">';
}

function template_main_below()
{
global $context, $settings, $options, $scripturl, $txt;

echo '
</td>


replase
<table cellspacing="0" cellpadding="10" border="0" align="center" width="95%" class="tborder">
<tr><td valign="top" width="120"><a href="http://www.simplemachines.org/">Link 1</a></td><td valign="top" bgcolor="#ffffff">';
}

function template_main_below()
{
global $context, $settings, $options, $scripturl, $txt;

echo '
</td>




Former Lead Support Specialist

Tarvitsetko apua SMF foorumisi kanssa? Otan työtehtäviä vastaan, lue:http://www.simplemachines.org/community/index.php?topic=375918.0

Advertisement: