Advertisement:
2by2host

Author Topic: Border thickness?  (Read 1433 times)

Offline Ashelia

  • Semi-Newbie
  • *
  • Posts: 69
  • Gender: Female
Border thickness?
« on: April 30, 2012, 02:04:15 PM »
I'm trying to decrease the white border thickness in forum/board listing to something like 1px, but I can't seem to find it anywhere in the default CSS file.. could anyone give me some directions?

Image below:


Offline IchBin™

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,920
  • Gender: Male
  • I don't speak German.
    • IchBin.us
Re: Border thickness?
« Reply #1 on: May 01, 2012, 01:06:14 PM »
It's relying on the fact that browser's put a default padding/spacing on tables when you don't specify them.

<table class="table_list"> in the template is where you need to add cellspacing="1" cellpadding="0" if you want the border smaller.
Brad "IchBin™" Grow        TinyPortal        Themes
Coding Guidelines       

Offline Ashelia

  • Semi-Newbie
  • *
  • Posts: 69
  • Gender: Female
Re: Border thickness?
« Reply #2 on: May 01, 2012, 03:19:48 PM »
Thank you, that worked. :)

Offline Ashelia

  • Semi-Newbie
  • *
  • Posts: 69
  • Gender: Female
Re: Border thickness?
« Reply #3 on: July 16, 2012, 05:18:54 PM »
Another similar question, if I wanted to do this for threads, which file/template would I have to edit?

I'm referring to the same thickness/spacing between actual posts and headers within a topic.

Online Orangine

  • Full Member
  • ***
  • Posts: 659
  • Gender: Female
Re: Border thickness?
« Reply #4 on: July 16, 2012, 05:37:24 PM »
same css file

if you're using Firefox, then download Firebug, it will save you a lot of time

Offline NBK*Twitch

  • Full Member
  • ***
  • Posts: 611
  • Gender: Male
    • Twitch's World
Re: Border thickness?
« Reply #5 on: July 16, 2012, 06:00:25 PM »
Another similar question, if I wanted to do this for threads, which file/template would I have to edit?

I'm referring to the same thickness/spacing between actual posts and headers within a topic.


Go to the table class in the css (about line 27)


Replace it with this -


Code: [Select]



/* Tables should show empty cells. */
table
{
empty-cells: show;
border-spacing: 0;
display: table;
}

Twitch's WorldFree Computer Support Forum - My SMF Themes - For affordable custom themes PM me

Offline Antechinus

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 22,051
  • Master of BBC Abuse
Re: Border thickness?
« Reply #6 on: July 16, 2012, 06:21:42 PM »
I'm trying to decrease the white border thickness in forum/board listing to something like 1px, but I can't seem to find it anywhere in the default CSS file.. could anyone give me some directions?

Image below:



I know Ich Bin has already given you a correct answer for this, but if you are interested in taking the concept further there is another option that can be implemented just by CSS changes.

What can you do is use border-collapse: collapse; on the table_list class in index.css. This will remove all visible borders between table cells and rows. You can also do this by using cellspacing="0" in the template, but border-collapse has an advantage.

What it allows you to do is choose which cells have borders and where they have them. It removes the default gaps, but still allows setting a border via CSS. If you only want borders between rows, you can have those without any others. If you want to remove the vertical border between the on/off icon and the board name, you can do that. Etc, etc.

If you are interested in playing around with this, I suggest checking out the CSS for the table_grid class. :)



@ NBK*Twitch: no that's not correct.

To change that stuff, looks for #forumposts in index.css. Specifically, you want top and bottom margins for div.cat_bar and div.windowbg and div.windowbg2.
« Last Edit: July 16, 2012, 07:27:46 PM by Antechinus »
"My idea of heaven consists of all the things I would go to Hell for."

I need another coding language like I need tertiary syphilis.

Antechinus modzRantyheinous themez - PSD pack for 2.0.x default theme