@Ted @Fargle There are really neat examples in $C(\mathbb{R},\mathbb{R})$ (where multiplication is pointwise multiplication). Units in this ring are just nowhere-zero functions, i.e. those of constant sign, so two associated functions have the same sign everywhere. On the other hand, for $g$ to divide $f$ is just to ask that $g$ is non-zero whenever $f$ is non-zero.
So take two functions having the same sign on $(-\infty,0)$, have them be zero on $[0,1]$, then let them have different signs on $(1,\infty)$. They divide each other, hence generate the same ideal, but aren't associate.