css

What tag should I use instead of deprecated tag font in html (cannot use CSS)

Hi, this question can create a misunderstanding: I know I have to use CSS to validate successfully my document as XHTML 1.0 Transitional. The fact is that I have to embed in my webpage a picture composed by zeros and ones created with text image, and the problem is that the code uses deprecated tag font and looks like this <!-- IMAGE BE...

How can I send html mails with included CSS with PHPmailer?

Hi all, I have problem with sending HTML mails with PHPmailer. I make Smarty template and I got all the HTML code from it but when I send mail, I got the mail witouth included CSS (it's only background-color, font or something like that). In PHPmailer I set that the mail is HTML. Is there any way to send HTML mail with included CSS? T...

IE6 sometimes not loading stylesheet

Hi We are having a problem where IE6 (the only browser we have noticed this happening on) seems to be caching an empty version of our main stylesheet. The only way to resolve the problem is to request the stylesheet directly by typing the its url directly into the browser, and then when you refresh the page, it will appear with the sty...

How to code html mailings?

Hello! I'm preparing to send mass email to customers which is in html + images. What are general rules to do make it display correctly in most popular mail clients? EDIT: Well it's for my customers - about few k clients. My question is - how to code this email that it will display correctly in customer mailclient(thunderbird, outloo...

styling the last td in a table with css

I want to style the last TD in a table without using a CSS class on the particular TD. <table> <tbody> <tr> <td>One</td> <td>Two</td> <td>Three</td> <td>Four</td> <td>Five</td> </tr> </tbody> </table> table td { border: 1px solid black; } I want the TD containing the text "Five" to not ha...

Defining styles for combinations of classes

Is there a way to define styles for a combination of classes? For example, I'd like my HTML to look like this, but the output to render in the appropriate color: <span class="red">Red Text</span><br/> <span class="green">Green Text</span><br/> <span class="red green">Yellow Text</span><br/> Edit: The above seems to be confusing peopl...

vertically stack table td elements using css

Hi, Is there a way to vertically stack selected td elments? I would like to have the same table, though display it differently using only css. Would this be possible, or do I have to have separate html markups? I would like to try to have the same html markup, though use different css for different sites/looks. <table> <tr> <td ...

Is it possible to put text on 3d button in HTML ?

I want to use pretty 3d button images on my website. However, currently the way this works is the text is part of the image. So, when I want to change the text (or make a new button) it's a 10 minute editing chore instead of a 20 second text change. I've seen a few websites that have a blank button with text on it. The real trick is m...

How can I get desired z-index behavior from IE when using nested DIVs?

I have three DIVs, something like this: <div id="header"> ... </div> <div id="content"> <div id="popup"> ... </div> </div> DIV#header is "position: fixed" and used as a non-scrolling header at the top of the screen. DIV#content has some content in it and is "position: relative". DIV#popup is "position: absolute" ...

IE6 extra padding on bottom

I have a div tag styled through CSS. I set the padding to 10px (padding:10px), it works just as I wanted in Firefox and IE7, but in IE6 it adds additional padding at the bottom (about 2-3px I think). Anyone has idea about what's happening here? [update] I just noticed this, the div tag I'm talking about has a background-image. When I ...

Curved corner border for a div

Hi friends, I need to build a div with curved corner border, with out using any images in the corner. Is it possible? I dont want to insert curved images in the corner, Please help me regarding this. ...

Google Chrome Bug with CSS Padding style applying to empty cells

Hello there. I have a problem only in Google Chrome (Firefox, IE, Netscape, Safari and Opera are Okay) where a padding property which should be applied to text in a cell, is being applied to all empty cells aswell. It's easy to solve by adding more specific styles to my affected perimeter cells and using different styles, but that uses a...

What are the best books on HTML and CSS?

I've been using HTML and CSS for years, and I'm pretty proficient but I'm continually frustrated by browser compatibility issues. Are there any notable books that have helped you understand the details of HTML and CSS and write compatible markup? ...

Valid CSS, XHTML logo generator

I once knew a website where the user could generate the little W3C valid CSS tags which looked much nicer than the too large W3C official ones. It was also possible to fill the icons with whatever content and color for other stuff. I've lost the bookmark and wasn't able to google it, can you post it and maybe other such resources? EDIT...

Relative path to a stylesheet in Visual studio not working in preview

Hi, I'm assuming this is an easy question, but I'll be darned if I can find the answer. I have a website in Visual Studio 2008. The paths to the stylesheets (and images) are in the following format /css/stylesheetname.css At the root of the web project in Visual studio the folder exists as does the stylesheet. These paths work fine wh...

Universal Dropdown Menu?

I am trying to create a "quick links" dropdown for a site I'm designing and it has to be compatible for all browsers IE6 and up. It needs to remain 120px wide because its position will be static. Using the < select > command and setting a width, this works; however, when the box is opened, IE cuts off the longer texted links where Firefo...

Hide something with CSS without display:none or JavaScript

How can I hide the div without using display:none or JavaScript? In my country, a lot of Blackberrys come with the CSS support disabled (the mobile companies here are not so good to developers). I have text that says <div class="BBwarn"> please activate your css support and a link </div> I want to hide that once the user activates CS...

How to wrap long lines without spaces in HTML?

If a user types in a long line without any spaces or white space, it will break formating by going wider than the current element. Something like: HAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHA............................................................................................................................................. I've tr...

How to slide content opening up with jquery

My designer handed me a design I'm not 100% sure how to do with jquery and css. I am basicly trying to allow a user to "slide" the footer up to reveal more conent. My html.. <div id="footer"> <div id="expandingFooter"> hidden content</div> content that is always visible </div> I have a toggle button that onclick $('#e...

Change the tab size on an element with word-wrap: pre?

I have an element that is similar to a tag (because it has word-wrap: pre;) to display code on a website. The only problem is that the tab size is too large and causes the element to horizontally scroll often because it is of fixed width. Is it possible to change the tab size? ...