E-com DevBlog Spider-ball-vacuum

19Dec/080

DD_belatedPngFix – A new solution to an aging problem

This has already been reported on several tutorial/dev sites, but I thought I'd put in a word or two about it.  DD_belatedPngFix is a fantastic little piece of work created by Drew Diller.  Drew has taken a unique approach to fixing the many issues that plauge ie6 and png files.  Instead of the standard alphaimageloader he uses just a touch of VML to tweak the images into appearing correctly, this allows for png files to be used as backgrounds and eliminates the annoying problem of trying to click on an image/div/whatever that was in another div with a background set to a png.

I started to set NordicTrack up with this script, but found that it's not quite perfected with objects that have absolute positioning (if anything on the page is a png that is above where your positioning the absolute element, they will build themselves as blocks, then knock each other out of the way), or with png sprites (your roll-over image is zoomed in a little so it appears 'cut-off').  Drew is regularly updating his script (which is awesome) so hopefully he'll have these issues fixed soon. --UPDATE (03/19/2009)! So after doing a bit more research (and a few updates to the js from Drew) this may no longer be an issue. If you remove the "position: relative, z-index: 1" from your png elements (or containers) the dd_belated png fix will work like a champ! NordicTrack has been converted and has been running dd_belated for just over a month now (so go and firebug the code ;) and see how I made it work) with no crazy formatting errors!

So in short, if you need a png fix that is simple, easy, and you don't want to throw "position: relative; z-index: 1" on all your elements that have a png in them (or as a background).  This is definetly something you'll want to check out.

Here's that link again, in case you missed it -> http://www.dillerdesign.com/experiment/DD_belatedPNG/ .

Print This Post Print This Post
9Dec/082

The economy tanked and Team Awesome was destroyed

Yesterday we recieved shocking, horrible, soul-destroying news.  Team Awesome would be broken apart and fed to the wolves. I am sure this was not an easy decision, and the hours of sleep that were (and are) missed are but a small tribute to the pain that our department now feels.  Our company decided that we all needed to cut spending, so four people from our department were shown the hatch.  Of the four, we lost Dustin and Ninja effectivly cutting Team Awesome in half.  Two others were thrown into the fray, Branden from Ryan's Team, and Ben... our 'one man island party planning genius with flair' (although our customer service dept hired him as an email tech).

We recieved more company emails and heard stories from the other departments (the other MIS team lost 6 people), but some of us are still here, it's just colder and lonelier.

Anyway, here's to Dustin,Ninja, Branden, and Ben. May some karma kick in and get you guys something nice (sound of a lid opening), here's one for me (swig), and four for my homies...

(As a side note, I hope that Dustin, Ninja, Ben, and Branden will continue to post here, because you guys will always be welcome here)

Print This Post Print This Post
3Dec/080

A quick post (based on a google search) about WCParam

I was reviewing my logs and noticed that two people happened to hit the site looking for an explanation on how to add a parameter to WCParam.  So I thought I'd take a minute or two and write up a  quick example using JSTL.

What you need to do is add the parameter in your c:url tag as a parameter when you define it. Let's say that I have a value that I am taking from a c:forEach loop (with a var="items"), we'll call it 'otherId' (since I'm going to pass this through the location/address-bar). I am also going to pass a langId (language code), a storeId (we're all about commerce), a catalogId (yep, we like to sell things), and finally my otherId. Using the code below (and yes I'm skipping setting up your command or whatever you are passing to) I can set up a quick c:url tag with my custom parameter in it that I can then access through the ${WCParam.otherId} on the page that I go to.

You must be using the 'c' tag lib for this to work, so don't forget to include that on your page, here we go.

?View Code HTML4STRICT
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
 
<c:url var="myURL" context="${CommandContext.webpath}" value="/mycmd">
   <c:param name="langId" value="${langId}" />
   <c:param name="storeId" value="${WCParam.storeId}" />
   <c:param name="catalogId" value="${WCParam.catalogId}" />
   <c:param name="otherId" value="${items.otherId}" />
</c:url>

And that, in a quick nut shell is how you get a variable accessible through your WCParam. Remember, WCParam is pretty much the same as saying, 'grab it from the location/address/url-bar'.

Feel free to drop corrections and comments (and yes I realize that my code box says HTML4STRICT, until it supports JSP code, HTML4STRICT is what you get).

Print This Post Print This Post