News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Please explain WHY people LIKE SIDEBARS !?!?!

Started by ladynada, April 29, 2007, 01:06:03 AM

Previous topic - Next topic

Sammy95

Well, first of all I didn't know that I liked sidebars  ;)

But then again...  after a second thought...

Maybe it's nice since my laptop is running 1200x800
and that gives me more space on the sides than on the top/bottom.

Sammy :)

KGIII

For the most part I dislike them with the exception of those rare times when they provide either information that I need or those times that they make my navigation more simplified/quicker.

My PC Support Forum
Please ask in-thread before PMing
                   SMF Help
                   Visit My Blog

How can we improve the support process?:
http://www.simplemachines.org/community/index.php?topic=163533.0

SMF vs. Godzilla? Who do you think will win?

Dannii

If you dislike them, it's only because you haven't seen them used properly. Which is fair enough... it is pretty rare to see them used properly.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

ladynada

Quote from: eldʌkaː on May 14, 2007, 08:38:27 PM
If you dislike them, it's only because you haven't seen them used properly. Which is fair enough... it is pretty rare to see them used properly.

I believe that I have been converted, because while working on this theme with a left sidebar, I am so used to it, then when I go to my live forum, I keep pointing over there for everything!

I like it alot.

I was able to leave some code in there with commented instructions for adding a right side bar.

regards,
nada
WORK for Truth, Print it, Take Time to READ ALL LINKS NOTED  click here --> The TWO Witnesses are Mom and Dad and SMF Skins

piroman

Dear Nada,

THANK YOU! You made my wish come true! I have a random img block form gallery in my smf site now, but I still have to ask you for small help. After I've added your example left sidebar, to my aero79 theme, my forum shrunk, could you help me fix this issue?

regs
Piroman

ladynada

Quote from: piroman on May 15, 2007, 09:39:55 AM
Dear Nada,

THANK YOU! You made my wish come true! I have a random img block form gallery in my smf site now, but I still have to ask you for small help. After I've added your example left sidebar, to my aero79 theme, my forum shrunk, could you help me fix this issue?

<snip picture>

Looking at the photo, because your logo is full size, I suspect you have an html code after the menubar section that is limiting your template_main section to less than full width.

If you added this to any html :  class="sidebar200"
and you set this in your styles.css

.sidebar200
{
   width: 200px;
}

or something like that, then check to see that you have these things set the way you want.

if it is not that, then if you used this section of code below, then look here for something..



// the menu buttons strip ended above

// all the main screen content starts here, so arrange your tables here
// The main content should go here.  A table is used because IE 6 just can't handle a div.

echo '
<table id="bodyarea" valign="top" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="2" valign="top" align="center">';

// BEFORE this routine ends, whatever the user has selected will be displayed
// And the file that controls what is displayed has to have a  template_main() function
// that function will display and then give control to the template_main_below() function below
// therefore, you must close out any tables started before the template_main function
// close them out at the beginning of this template_main_below funtction below
echo '
<table class="sidebar200" border="0" cellpadding="0" cellspacing="0">';
// add your left sidebar in here, use the class sidebar200 in sytles.css to set the width
echo '
<tr>
<td class="forum_stats">';
echo '
', $txt[645], '<br />
', $txt[19], ': ', $context['common_stats']['total_members'], ' <br />', $txt[95], ': ', $context['common_stats']['total_posts'], ' <br />',  $txt[64], ': ', $context['common_stats']['total_topics'], '
', ($settings['show_latest_member'] ? '<br /> New User:' .  ' <b>' . $context['common_stats']['latest_member']['link'] . '</b>' : '');
echo '
</td>
</tr>
</table>';

// In order to have user selection display NEXT to sidebar, open another <td>

echo '
</td>
<td>';



// the bracket below ends the function template_main_above() section !!



Look here at the bottom part where you open a new td for your main body section, which has shrunk.. did you open a new table there?  did you set the width="100%" there... something like that

also, when looking to solve these kinds of problems, go ahead and use the xhtml validator button at the bottom of your forum
http://validator.w3.org/check/referer

and use the... Revalidate With Options and check the Show Source button and run it again, then it will show you where the errors are in your code!  this helps me fix the table-tr-td  mis-matches

lemme know  how you make out.

I am sooooo glad you got the gallery to work.

nada
WORK for Truth, Print it, Take Time to READ ALL LINKS NOTED  click here --> The TWO Witnesses are Mom and Dad and SMF Skins

Deaks

lady, it depends on the theme, tbh, when i design a theme i think of how i want it to look and try both normal and side and see what one works with the theme :)

Neither is better nor worse
~~~~
Former SMF Project Manager
Former SMF Customizer

"For as lang as hunner o us is in life, in nae wey
will we thole the Soothron tae owergang us. In truth it isna for glory, or wealth, or
honours that we fecht, but for freedom alane, that nae honest cheil gies up but wi life
itsel."

Teaberry

ladynada ~

Thanks for all of your explanations. You are very thorough and clear.

Do these directions work for all themes or just the Default? I am using the Electron theme, and I can't seem to get that right sidebar up that I want so desperately to be there.

ladynada

Teaberry,

In general the instructions should 'help' you to make the same adjustments for all themes.  I am not familiar with the electron theme, but if you approach the task by understanding what that theme is doing, then it will dawn on you where to intervene to make your right sidebar.

Sometimes I practice by taking a section OUT of a theme, and then looking to see how it comes out, to understand how the theme is displaying.

The flow is the most important thing to understand; above - main - below

If you have some specific code for me to look at, maybe I can help you figure it out (with God's help).

nada
WORK for Truth, Print it, Take Time to READ ALL LINKS NOTED  click here --> The TWO Witnesses are Mom and Dad and SMF Skins

Teaberry

Thank you nada. If you don't mind, which pages of code would you like to see?

ladynada

Quote from: Teaberry on June 05, 2007, 09:22:47 PM
Thank you nada. If you don't mind, which pages of code would you like to see?

here is the link to the theme for anyone who wants to peak at it
http://custom.simplemachines.org/themes/index.php?lemma=67

This is a very nice theme!

Well, I am thinking that the most important issue is what are you trying to put in the right sidebar?  Also, are you trying to make a THREE column theme out of it?  Are you putting BOTH a left and right sidebar?

Please let me know, and I can probably just install the theme on my home pc and add the right side bar and post the code here for you. It would go in the Index.template.php file.

lemme know please,
nada
WORK for Truth, Print it, Take Time to READ ALL LINKS NOTED  click here --> The TWO Witnesses are Mom and Dad and SMF Skins

Teaberry

Nada ~

I am trying to place just a right sidebar. I'm interested in placing mainly links there and some click-thrus. Nothing seems to work!

Thanks for your efforts. I really appreciate it! How nice.


ladynada

Hi,
I see why you had problems because quite a bit of the code is already modified.  I used the example I posted here and was able to make a little forum stats table in a right sidebar, and it held its spot through all the other forum options, and no errors in the forum log.

Here is the code, and you will find where it goes by looking at where this begins and ends.




function template_main_below()
{
global $context, $settings, $options, $scripturl, $txt;
//  These commands close out the table that was started in template_main_above() at bodyarea

echo '
</td>';
// The </td> above closed out the user's selected content, now you can show a RIGHT sidebar
// Open a new <td>

echo '
<td valign="top" align="center" width="200px">
<table border="0" cellpadding="0" cellspacing="0">';
// add your RIGHT sidebar in here
echo '
<tr>
<td>';
echo '
', $txt[645], '<br />
', $txt[19], ': ', $context['common_stats']['total_members'], ' <br />', $txt[95], ': ', $context['common_stats']['total_posts'], ' <br />',  $txt[64], ': ', $context['common_stats']['total_topics'], '
', ($settings['show_latest_member'] ? '<br /> New User:' .  ' <b>' . $context['common_stats']['latest_member']['link'] . '</b>' : '');
echo '
</td>
</tr>
</table>';
// Now close the entire two column main screen window with the closing </td>
echo '
</td>

</tr></table>';

// Show the "Powered by" and "Valid" logos, as well as the copyright.  Remember, the copyright must be somewhere!
echo '



Hope that works for you!
nada
WORK for Truth, Print it, Take Time to READ ALL LINKS NOTED  click here --> The TWO Witnesses are Mom and Dad and SMF Skins

Teaberry

Nada - that was a great help!!!!!

I'm presently working on it and tweaking it, but the right sidebar has made its guest appearance!

When I'm done I'll post my site and you can see. Many thanks again! How wonderful of you to help me.

ladynada

WORK for Truth, Print it, Take Time to READ ALL LINKS NOTED  click here --> The TWO Witnesses are Mom and Dad and SMF Skins

Advertisement: