Solved

No border on table

Posted on 2014-03-31
7
209 Views
Last Modified: 2014-03-31
Ive been trying to switch off the border of a cell of a table, Ive set the cell I dont want a border to have the class of .scollSpacer and coded it as:-
table .scollSpacer { width:15px; border:none; }

Open in new window


However the border is still showing on the cell (top right):-
http://jsfiddle.net/5DfGx/

Any idea how I can switch off the border of the class .scrollSpacer?

Thank you
0
Comment
Question by:tonelm54
  • 3
  • 2
  • 2
7 Comments
 

Author Comment

by:tonelm54
ID: 39967850
Im looking to have the border on all the cells apart from the cell with .scollSpacer
0
 

Author Comment

by:tonelm54
ID: 39967851
Im looking to have the border on all the cells apart from the cell with .scollSpacer
0
 
LVL 52

Expert Comment

by:Scott Fell, EE MVE
ID: 39967847
You are setting the border with css

table,th, td { border: 1px solid black; }

Open in new window


Just remove that and no border
http://jsfiddle.net/5DfGx/2/
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 10

Expert Comment

by:jtwcs
ID: 39967861
The border you are seeing is from the table border.  

Remove table from this declaration and just the cells and header will have a border.

table,th, td { border: 1px solid black; }

Open in new window

0
 
LVL 52

Accepted Solution

by:
Scott Fell,  EE MVE earned 500 total points
ID: 39967868
http://jsfiddle.net/5DfGx/6/

  #openJobs .tableBody { height:200px; }
  #openJobs th:nth-child(1), td:nth-child(1) { width:80px; }
  #openJobs th:nth-child(2), td:nth-child(2) { width:110px; }
  #openJobs th:nth-child(3), td:nth-child(3) { width:100px; }
  #openJobs th:nth-child(4), td:nth-child(4) { width:300px; }
  #openJobs th { text-align:left; }
  
  table { border-collapse:collapse; }
  table,th, td { border: 1px solid black; }
  table .scollSpacer { width:15px; border:none; }
  
  .tableBody tr:nth-child(odd) { background-color:#eee; }
  .tableBody tr:nth-child(even) { background-color:#fff; }

/* added */
table{border:none;}
th.scollSpacer{border:none;}

Open in new window

0
 
LVL 10

Expert Comment

by:jtwcs
ID: 39967889
/* added */
table{border:none;}
th.scollSpacer{border:none;}

Open in new window


The above extra declarations are not necessary here.  

You just need to update
table,th, td { border: 1px solid black; }

Open in new window


to this
th, td { border: 1px solid black; }

Open in new window

0
 
LVL 52

Expert Comment

by:Scott Fell, EE MVE
ID: 39967904
jwtcs, maybe that works in the sample, but we don't know what the actual plans are and the request is, "have the border on all the cells apart from the cell with .scollSpacer"
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Under active page on navigation bar 8 19
Fix Form size HTML 16 30
CSS Style on Chrome 1 33
TypeError jquery issues with site - CSS conflicts 3 24
CSS3 Custom checkboxes This article shows how to style the checkbox form element using only CSS. Works in: Chrome, FF, Safari, Opera, IE9+ Uses modernizr.js to check for :checked pseudo class, falling back to plain old checkboxes (IE8 and bel…
Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer …
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

680 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question