Hi,

I couldn't find an answer to this by searching through the archives,
so apologies if this has been covered already.

Is there a straightforward and simple way of modifying certain kinds
of external trac links to contain javascript events?

For example, if i wanted to implement an "onClick" javascript function
when certain links were clicked (to track downloads with Google
Analytics), what's the best way to approach it?
I want my resulting HTML to look like this:
<a href="http://www.example.com/files/map.pdf";
onClick="javascript:urchinTracker ('/downloads/map'); ">

I've tried using the {{{ #!html }}} HTML processor to add javascript
explicitly but that has been specifically disallowed as of bug 983.

Are there any other suggestions? i'd rather not put javascript
directly into CSS. Is there a plugin that will allow me to implement
this functionality?

thanks in advance.

--
Toli Kuznets
http://www.marketcetera.com: Open-Source Trading Platform
download.run.trade.
_______________________________________________
Trac mailing list
[email protected]
http://lists.edgewall.com/mailman/listinfo/trac

Reply via email to