Re: SVG Script in Firefox troubles

Dale Ellis <[email protected]> Tue, 13 Oct 2009 02:36:49 -0700 (PDT)
Newsgroups gmane.comp.mozilla.devel.svg
Organization http://groups.google.com
Message-ID <147d21f8-6bdf-4ef7-b4ac-ff9305991f3b@x37g2000yqj.googlegroups.com>
On Oct 12, 6:21 pm, Boris Zbarsky <[email protected]> wrote:
> On 10/12/09 12:54 PM, Dale Ellis wrote:
>
> > I do have another question, how do you make the cursor be a hand?
>
> "cursor: pointer" in CSS.
>
> > <a xlink:href="">
>
> You can probably toss in onclick="return false;" to make that work
> across the board, but the CSS approach might be better.
>
> -Boris

Thanks for you help again Boris, as I mentioned the cursor doesn't
seem to work in IE, its fine in FF. I had already tried onClick return
false previous to that. Did find a way around it <a
xlink:href="javascript:void(1);">

Its pretty much all working now in FF, just one small bit left, this
function doesn't seem to be working in FF, a function which draws a
triangle...

function drawTriangle(direction, x, y) {
    var tri = svgdoc.createElementNS(SVG_NS, 'use');
    tri.setAttributeNS('http://www.w3.org/2000/xlink/namespace/',
'xlink:href', '#'+direction);
    tri.setAttributeNS(null, 'transform', 'translate('+ x +', '+ y
+')');
    svgdoc.getElementById('taskDependecies').appendChild(tri);
}

Again, fine in IE, just checked the data coming through, all valid x
and y values, and valid id's in the direction field for pre defined
polygons.

Anything look wrong in there?