Admins eHow SysAdmin Tips & Tricks

May 31, 2009

Wrap text in pre tag

Filed under: CSS,HTML — Tags: , , , , — admin @ 5:21 pm

use the following CSS code to wrap the lines in a pre html tag :

pre {
white-space: -moz-pre-wrap; /* Mozilla, supported since 1999 */
white-space: -pre-wrap; /* Opera 4 - 6 */
white-space: -o-pre-wrap; /* Opera 7 */
white-space: pre-wrap; /* CSS3 - Text module (Candidate Recommendation) http://www.w3.org/TR/css3-text/#white-space */
word-wrap: break-word; /* IE 5.5+ */
}

May 12, 2009

How to apply multiple css classes to an HTML element

Filed under: CSS,General — Tags: , , , — admin @ 9:54 am

Applying multiple css classes to an HTML element is easy , simply put an space between classes.
Example :

<style>;
.class1 {color:red;}
.class2 {background-color:blue;}
</style>;
<tr class="class1 class2"><td>< an example</td></tr>

Powered by WordPress