how to replace text on a page using Javascript code

T

Tony Strazzeri

Hi,

I recently posted "problem with Javascript code from Include"
Thanks to response I have now fixed the problem.

This is to ask how to solve my next problem/step.

I am using javascript to create my email address on the fly so as to
avoid SPAM harvesters.

I like to see where I have placed the email address during design time.
What I am doing now is setting the marker text as hidden so it appears
at design time but is invisible at run time.

I use this code to display the spot followed by the call to create the
address.
Send Email to: <span style="visibility: hidden">mailAddyFor:
'Address_for_Info' </span>
<script language="javascript"
type="text/javascript">generate_address('Address_for_Info')</script>

The problem with this is that even though the marker is set to
invisible it still holds space and forces the address to appear away
from the label "Send Email to: ".

It appears as;
"Send Email
to:[email protected]"
Note: the "_" are actually spaces.

Instead of; "Send Email to: (e-mail address removed)"

Is there a way I can remove the entire marker text programmatically
(say from within the code that creates the address)?

Cheers
TonyS.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top