[l2h] \externalref adds extra <IMG> inside \HTMLcode

Ross Moore ross at ics.mq.edu.au
Fri Mar 7 18:14:18 CET 2003


Hello Bill,

You wrote:

> I have a question about using \externalref with \HTMLcode.  I have the
> following to add some mouse over/out action codes to a link: 
> 
> \HTMLcode[HREF="junk",onmouseover="over()",onmouseout="out()"]{A}{PGP
> Public Key}
> <A ONMOUSEOUT="out()" ONMOUSEOVER="over()" HREF="junk">PGP Public Key</A>
> 
> However, when I change the HREF to refer to an \externalref label:
> 
> \HTMLcode[HREF="\externalref{martin.webpage.publickey}",onmouseover="over()",on\
> mouseout="out()"]{A}{PGP Public Key}

\externalref is a high-level command which constructs the complete
reference, anchor and all:
   <A HREF="....">.....</A>
 
> I get the following:
> 
> <A ONMOUSEOUT="out()" ONMOUSEOVER="over()" HREF="<A
                                                   ^^^
> HREF="#martin.webpage.publickey">
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> <IMG  ALIGN="BOTTOM" BORDER="1" ALT="[*]"
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>  SRC="http://www.orie.cornell.edu/icons/crossref.gif"></A>">PGP Public 
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> Key</A>

> Why is the <IMG> statement added?  How do I suppress it?

It's not just the <IMG> which is added.
\externalref is not intended for use inside \HTMLcode 
as it generates its own HTML tagging.


Given that the external reference is independent of the current
document, so is effectively constant, then you could just use
a simple macro:

\newcommand{\martinURL}{.....URL to the external document's label....}

\HTMLcode[HREF="\martinURL",....]{A}{PGP Public Key}


Hope this helps,

	Ross Moore


> 
> Thank you,
> 
> -- Bill Martin --
> 
> -- 
> =======================================================================
> William T. Martin		email:	martin at orie.cornell.edu
> Cornell University/ORIE		
> =======================================================================
> _______________________________________________
> latex2html mailing list
> latex2html at tug.org
> http://tug.org/mailman/listinfo/latex2html



More information about the latex2html mailing list