maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ed Hillmann <>
Subject Q: How can I define a link that calls a Javascript function?
Date Wed, 02 Sep 2009 03:57:13 GMT
Hi all.  I've trying to write some documentation in xdoc, that defines web
pages that are generated by Maven.

I've been able to update the site.xml document so that I can define some
Javascript functions in the HTML's <head> element.  That's all good.  When I
generate the page, I can see the Javascript methods where I expect them.

My problem is trying to call them using an anchor element.  Whenever I
define an anchor element that tries to call the javascript function

<a href="javascript:FunctionName">

the link that is generated thinks I mean an anchor in the same page.  So, it
comes out

<a href=path/to/html/file.html#javascript:FunctionName">

So, when I click on it, nothing happens because there's no achor with that

Is there a specific syntax I should be using to get the anchors defined so
that they can call javascript methods defined within the HTML itself?

Thanks for any help,

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message