My name is Edward Tanguay. I am a web developer in Berlin, Germany. I learn everything I can and record it on this site.
Other things you might be looking for:
My Ubuntu Tutorial
My Datapod Project
My Blog Feed:
- Code Examples
Code Example: How to position text in a div with left and right areas
CSS CODE EXAMPLE - added on June 30, 2008
How to position text in a div with left and right areas 
This CSS script give you absolute pixel-exact control of where to place text in a left and right area of a wide div, e.g. a header or footer. I was not able to get it to align automatically, e.g. left/center/right, so you have to know your font size and your text and position things exactly, but at least you have control, checked in Firefox and Explorer.
patryksharks321: nice code btw relative is according to the last element and absolute is towards the block it's in right? greetings
arrow pointing right
reply
post comment or question
Similar Code Examples:
Code Example: Large button links with A elements
CSS CODE EXAMPLE - added on August 12, 2008
Many times you want to have a menu with A elements as the links instead of e.g. LI elements. Here is an example with large buttons. See example here.
SHOW CODE

post comment or question
Code Example: Simple CSS-only layout with top menu
CSS CODE EXAMPLE - added on May 20, 2008
Here is a layout for a non-flashy interface for e.g. a website tool. Solves the issue of floating divs with a clear:all div, here's an example.
SHOW CODE

post comment or question
Code Example: Simple and Expandable CSS Menu
CSS CODE EXAMPLE - added on March 22, 2008
This CSS example shows a simple UL/LI menu absolutely positioned top/left and a line-height of 1em and the body pushes the container div down 1em so that you can expand the font (ctrl-+) and the menu stays relatively sized to the content of the site. Ok, I'm starting to see how if you set even the amount of space between screen objects to the same unit (em) as the font then you have a flexible layout that someone with poor eyesite can just zoom in (I wonder if you could have your graphics expand as well). This is also cool because in the body tag you have font-size: 94% and if you change this then everything stays in proportion as well. Here is a live example.
SHOW CODE

post comment or question
Code Example: Background images relative to CSS file not HTML file
CSS CODE EXAMPLE - added on March 21, 2008
I have always wondered why background images never worked when specified in the CSS file but DID work when specified inline in the HTML tag. The reason is that you have to define the path of the image relative to the position of the CSS file to the image, and inline definitions use the path relative to the position of the HTML file to the image. Nice to know.
SHOW CODE

Patrick Wright: IIRC, this is how CSS Zen Garden handles its magic--each CSS is in its own location and pulls in its own background images relative to the CSS file, which allows the main XHTML file to remain unchanged. We actually missed that aspect of the CSS spec early on in developing our rendering tool. Cheers!
arrow pointing right
Edward: Thanks for reminding me to go back to CSS Garden and humble myself, that site is so impressive. When I look at the designs with Firefox and Explorer 7 they look exactly the same, I wonder how they look on Explorer 5.0 for mac and Netscape 4 etc. I wonder if you are allowed to use hacks or if it is a purity contest.
arrow pointing right
reply
post comment or question
Code Example: Table-less Pure-CSS Form using Fieldset and Label Elements
CSS CODE EXAMPLE - added on March 8, 2008
So finally a form without HTML tables, finally got all the floats: left, right, clear both etc. correct. I have this pretty fixed to a certain size just because I don't like my forms being stretched across the page as the browser area grows (would be ok if the font sizes also grew but they don't so it's just a design integrity issue), if you want this ability (better for expanding the size of the font) just change most of the px values (especially for width and margin) to percent values and your form will stretch as needed. VIEW EXAMPLE HERE.
SHOW CODE

post comment or question
Code Example: Pure CSS Layout: Two Columns, Components, Non-Graphic Hover Menu
CSS CODE EXAMPLE - added on March 4, 2008
Here is a HTML/CSS site layout with no tables, tested in IE7/Firefox, hover menu without graphics and a modular design so you can add components in the two columns as you wish. VIEW EXAMPLE HERE.
SHOW CODE

Patrick Wright: Hi Ed--when I come across CSS samples like this, I usually want to see them in use immediately--if you had a link to the page itself that I could clck on to see the effect that would be great. Cheers, Patrick
arrow pointing right
Edward: Excellent idea, for now I put a VIEW EXAMPLE HERE link is above. I have planned to make layout examples automatically have thumbnail examples and links to full examples, just not programmed yet. Thanks.
arrow pointing right
reply
sgt: Thanks for posting great tips and code snippets that can save some effort for beginners.
arrow pointing right
reply
post comment or question
Code Example: Pure CSS Layout: Two Columns, Centered with Rounded Box Components
CSS CODE EXAMPLE - added on February 29, 2008
This layout has two columns with a dividing line in the middle (bug: which only goes down to the bottom if MORE content is on the left side than on the right side) and it is filled with rounded boxes with various colored headers, all done without graphics, which is very nice. This would be good code to get into presentation objects so these things are very easy to make and drag- and droppable.
SHOW CODE

post comment or question
Code Example: CSS for a three-column layout
CSS CODE EXAMPLE - added on February 14, 2008
This was my first fully non-table column-layout in CSS that I am satisfied with, note that if you put the width of the body_wrapper to 100% it will also work but a user can scrunch the whole site back to the left, which isn't really desirable, and min_width can't really be relied upon from my experience but that my be a solution, a solid px width works well though, with this layout you just have to be sure that your graphics are less wide than your column widths or they will hang over into the next column, unlike the nice feature of tables where the column expands to the width of the widest graphic. See the example here.
SHOW CODE

post comment or question
Code Example: Base CSS for making a data table with divs and spans
CSS CODE EXAMPLE - added on December 3, 2007
If you need to avoid HTML tables but need to order information in rows and columsn, etc. start with this code.
SHOW CODE

post comment or question
My Free Tutorials:
Tutorial: How to Install the Android SDK on Windows XP and Create an Application that Runs in the Cell Phone Emulator
How to Install the Android SDK on Windows XP and Create an Application that Runs in the Cell Phone Emulator
Tutorial: How to Create a Website with Datapod
How to Create a Website with Datapod
Tutorial: Install Fedora 6 in VMWare on Windows XP and connect it to your network
Install Fedora 6 in VMWare on Windows XP and connect it to your network
Tutorial: Install Perl 5 on Windows XP and Get a Perl Hello World Running
Install Perl 5 on Windows XP and Get a Perl Hello World Running
Tutorial: Install OpenSuse 10.2 in VMWare on Windows XP and connect it to your network
Install OpenSuse 10.2 in VMWare on Windows XP and connect it to your network
Tutorial: Install Ubuntu 7.04 in VMWare on Windows XP and connect it to your network
Install Ubuntu 7.04 in VMWare on Windows XP and connect it to your network
Tutorial: Install Java on Windows XP and Learn the Basics of Java 6 using the NetBeans IDE
Install Java on Windows XP and Learn the Basics of Java 6 using the NetBeans IDE
Tutorial: Setup a PHP Development Environment on Windows XP With Apache, PHP 5, MySQL 5, SQLite, Eclipse, Subversion, PHPMyAdmin, and Datapod
Setup a PHP Development Environment on Windows XP With Apache, PHP 5, MySQL 5, SQLite, Eclipse, Subversion, PHPMyAdmin, and Datapod
Tutorial: Install a PHP Development Environment with Eclipse PDT, Apache 2.2, PHP 5, MySQL 5, and phpMyAdmin Using XAMPP Lite
Install a PHP Development Environment with Eclipse PDT, Apache 2.2, PHP 5, MySQL 5, and phpMyAdmin Using XAMPP Lite
Tutorial: How to Install Ruby on Rails with Instant Rails and Create a Website Using JEdit and the Ruby Plugin
How to Install Ruby on Rails with Instant Rails and Create a Website Using JEdit and the Ruby Plugin
This site was made with Datapod.