aspose file tools*
The moose likes Beginning Java and the fly likes email hyperlink Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "email hyperlink" Watch "email hyperlink" New topic

email hyperlink

Chris Pat
Ranch Hand

Joined: Aug 27, 2005
Posts: 156
I am trying to construct within a servlet an email with a hyperlink made up of the components. What I cant seem to do is escape successfully and have the resulting string include the ""
I want to appear in the message bode <a href="serverNameAndURI">clickMe</a>
I have tried building it with StringBuffer but still cant get the " correct. Can someone help with the proper technique and syntax.
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 60041

In Java, quote characters within string literals are escaped with the backslash character (\).

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Rahul Shilpakar
Ranch Hand

Joined: Aug 29, 2006
Posts: 132
you can write it as :

<pre name="code" class="core"> <a href="\"serverNameAndURI\"">clickMe</a> </pre>

Perform for today. Adapt for tomorrow.
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: email hyperlink
Similar Threads
Rollover effects within HTML
how to use command link in jsf
how to save data from vanishing during page navigation?
how to add data in request object and pass it to next page?
passing html text in a java String object