Wrox Programmer Forums
CSS Cascading Style Sheets All issues relating to Cascading Style Sheets (CSS).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the CSS Cascading Style Sheets section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old March 9th, 2011, 02:10 PM
Registered User
Join Date: Jan 2011
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Unhappy CSS rules not being followed

I work for a company with a Sharepoint 2007 site, and would like to change the search box from one to the right of the other to one on top of the other (see pics). I was able to get this to work in firefox by adding display:block to the style of the TD's of the search boxes. However, this fails in every other browser. In Chrome, it defaults to display:table-cell, and in IE, it is still showing display:block in the dev console, but it is still showing up inline on the actual page. Can anyone help me with this? For anyone unfamiliar with Sharepoint, the html structure looks like this:

               <TD class="ms-sbscopes ms-sbcell">dropdown box</td>
               <TD class="ms-sbcell">search box</td>
               <TD class="ms-sbgo ms-sbcell">go button</td>
CSS code that works only in Firefox:
td.ms-sbcell {
	background: #990000;
	padding-left: 5px;
	display:block !important;
Also, this MUST be done with css, I can't go arround and change the master page for some 500 sites. Is there something I am doing wrong? How can I fix this issue? Please view the images to get a better idea of what I am talking about. Thanks in advance!

What I want: (Firefox)

What I currently have: (Every other browser)
Old April 16th, 2011, 12:16 AM
Friend of Wrox
Join Date: Jun 2007
Posts: 477
Thanks: 10
Thanked 19 Times in 18 Posts

Wish I could be of more help. There's a lot of styling that you can do with tables, but messing with their display is an absolute @#%@&(&. <tr> tags don't play nicely with a lot of styling including borders, and I'm pretty amazed to see that you were able to get table cells to stack in any browser, much less the #2 browser on the internet. If you hadn't demonstrated it, I would have guessed that it was a waste of time trying. I appreciate all your efforts, and hope someone else has some black voodoo up their sleeve to modify this, but I've worked with CSS for years and trying to disrupt the "standard layout" of a table is ultra difficult as it sounds like you're finding out unfortunately. This is one of the reasons that table based layouts are falling out of favor, because it's virtually impossible to repurpose them like you want without hacking the XHTML of all 500 sites.

Whatever you can do or dream you can, begin it. Boldness has genius, power and magic in it. Begin it now.
-Johann von Goethe

When Two Hearts Race... Both Win.
-Dove Chocolate Wrapper

Chroniclemaster1, Founder of www.EarthChronicle.com
A Growing History of our Planet, by our Planet, for our Planet.

Similar Threads
Thread Thread Starter Forum Replies Last Post
XML database construction rules sani723 XML 1 July 4th, 2007 09:46 PM
Rules, that FxCop cannot check cyberjoe General .NET 1 May 6th, 2007 06:05 PM
Question within ASP business Rules. fkmfkm Classic ASP Basics 0 May 17th, 2005 10:33 PM
Rules/Constraints dhay1999 SQL Server 2000 1 July 11th, 2004 01:50 PM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.