Follow me on Twitter - twitter.com/lewiswalsh“I bought a television set for the first time in my life 52/366 #366 #project366 #earlybird #television http://t.co/xaobVgZ5

2011.09.13

Zen Coding


I've fallen hopelessly in love with Zen Coding (watch this video). But there is one thing that is bothering me. Does anyone know the syntax to produce the following:

<div>
    <div>
        <p></p>
    </div>
    <ul>
        <li></li>
    </ul>
</div>

If I use 'div>div>p+ul>li' then my UL ends up inside the second div, after the P tag, which is what I would expect. But it's not what I want.

EDIT: Nevermind, I figured it out:

div>(div>p)+(ul>li)

Strictly I could omit the parentheses from the second half of the string (the UL) but I think it looks neater and visually creates a distinct separation.

programming

Burst forth on 13th September 2011 at 14:40 and vaguely filed under programming.

Witty rejoinders


Nothing yet!

(never published)
http://
Captcha: