css: add text before or after

by prettyscripts on 2011-12-19 12:09:00 • Leave a comment »

css

use :before and :after psuedo elements with css property content. eg, to separate a list of items with '|': li:after { content: ' | '; } li:last-child:after { content: ''; } note line 2: no separater after the last item in the list. more »

Tags: content, css, text

yii: set and display generic global message

by prettyscripts on 2011-03-04 14:28:00 • Leave a comment »

phpcssyii

Yii has flash messages that's stored in session variables and is available in current and next requests. For some basic understanding, please read how to work with flash messages. The 3 basic functions used:Yii::app()->user->setFlash('key', '… more »

Tags: error, flash, message, notice, yii

css: box around floating elements

by prettyscripts on 2010-09-20 16:25:00 • Leave a comment »

csshtml

a common problem with when trying to box 2 floating elements, you see a zero-height box align to the top of the floating element. eg, we have the following layout:<div class="container"> <div class="left">left column</div>… more »

Tags: box, css, float

css and ie: clear

by prettyscripts on 2010-02-16 11:12:26 • Leave a comment »

css

i always have a clear class in my css to clear any floating elements:.clear { clear: both; } and commonly used in html code such as follows:<div id="floating_1">something</div><div class="clear"></div><div id="float… more »

Tags: clear, css, ie

css and ie: fixed position

by prettyscripts on 2009-11-19 11:24:05 • Leave a comment »

css

one of the things that’s not supported in internet explorer. the css 'position: fixed;' it works in IE7 and after. but not in older versions. thought people should upgrade their browser, there are still users limited to the older version. (why don’t yo… more »

Tags: css, ie, position