Skip to Main Content
MooTools 1.3 Cookbook
book

MooTools 1.3 Cookbook

by Jay L Johnston
July 2011
Intermediate to advanced content levelIntermediate to advanced
276 pages
5h 11m
English
Packt Publishing
Content preview from MooTools 1.3 Cookbook

Saving space on our site: expand text containers on focus

Continuing in our effort to save space, we will endeavor to expand text containers on focus.

Getting ready

Prepare our DOM for this recipe where each text field greets the focus from the user by expanding smoothly, create regular INPUT elements. The code snippet in the book also includes a TEXTAREA. Also define two states of CSS to represent both blurred and focused elements.

... <tr> <td align="right"><label for="name">Your Name</label></td> <td><input type="text" value="" name="name" id="name"></td> </tr> <tr> <td align="right"> <label for="email">Your Email Address</label> </td> <td> <input type="text" value="" name="email" id="email"> </td> </tr> ... <style type="text/css"> .blurred_element ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Jump Start Web Performance

Jump Start Web Performance

Craig Buckler

Publisher Resources

ISBN: 9781849515689Other