Archive for the ‘css’ Category

What it looks like to be you 2

January 17, 2006

In light of not being able to get all our Mac dreams to come true, we fell back on another solution.

Btw, if you use a 10-switch adapter to connect a VGA monitor to the Mac, the Belkin manual for their adapter is excellent. Mode 1 worked excellently for us.

We love snugtech’s Safari browser tester!It’s not as public as some other previewers we have come across and it’s dead easy. So, hooray.

What we love about snugtech is that it’s private. We have been racking our brains to find another site we saw once that previewed with Safari similarly, although (and this is a bad choice) it displays results publically. Behold, we have found it (when snugtech went offline for a bit): iCapture. Dan Vine, the creator of iCapture, also has a nice utility that allows you preview on IE, if you don’t have that browser (Mac users, I am looking at you): ieCapture (currently in alpha test).

Something we’d forgotten in terms of coding out a style sheet is making IE-specific attributes. Last year, we used Eric Meyers’ asterisk hack, and that is what we had forgotten. Today we used a variation on that theme from cavemonkey50, which he is calling an underscore hack. They have the same effect. In short, what you do is add a special character (say, an asterisk or an underscore) in front of an attribute, and only IE will read it.

How it works. Two things make it possible: 1) the cascade part of CSS, and 2) IE’s stupidity (to put it bluntly). So define your attribute for all browsers but IE first. Then redefinte your attribute with an underscore in front of it. Other browsers will see this as poorly formed and skip it. But IE will blindly read it, accept it as a redefinition in the cascade, and use the second malformed attribute instead.

some CSS references for project X

December 16, 2005

Sadly, we don’t use PHP and CSS every day, nor do we have people to talk with about them, so we scamper around the Internets a lot looking for information, help, and code examples.

One of the things we had to do with project X is make a pleasing design for end users. We consulted out books, but were uninspired. Besides, our books were “too fancy” for the project at hand. But happily, we found some inspiration in a british site that has downloadable web templates. We actually didn’t end up using any of their templates, but they were enough of a spark to get us focused on our end design.

We misplaced our facts about using images and links in CSS this project (our minds are growing fuzzy in the winter months–if only someone turned on the heat in this place!), so HTMLSource’s tips on using images with CSS helped a bit.

Also, there is the trickiness of making things appear and disappear in CSS. display: none and display:block to the rescue.

We really hate IE. Sure, we’ve been told that we will love IE7, but once bitten, twice shy and all of that. Still, we have to code with IE’s float errors and such. We love Position is Everything, and their page on magins, floats, and IE was a lifesaver. The problem is largely with varying box models. Thankfully, tantek has some nice box model hacks at the WaSP project that are nifty and helpful.

EDIT: Hey Mac users, Microsoft no longer has your back. Seems that after years of proprietary coding standards and forcing people to code especially for IE, MS is pulling the rug out from under Mac users. As of January 2006, they will no longer offer up downloads of IE, nor will they support it. The irony is that they recommend better, more standards-based browsers such as Safari and Opera. Which is exactly what we, as web developers, have been telling people to use for years.