How to place url link in gwt Label

1,464 views
Skip to first unread message

mariyan nenchev

unread,
Feb 10, 2010, 5:45:02 AM2/10/10
to Google Web Toolkit
Hi,
I have a label that contains some text and part of it must link:
For example the whole Label text is : bla bla bla. Reference:link, bla bla bla.
I tried : Reference : <a href="http://www.google.com">Help Desk</a>
But gwt doesn't detect it as url, may be i should use HTML?

Regards.

philippe

unread,
Feb 10, 2010, 8:16:47 AM2/10/10
to Google Web Toolkit
You can use Html object to make your Label.

Philippe

Ashar Lohmar

unread,
Feb 10, 2010, 8:19:01 AM2/10/10
to Google Web Toolkit
guess what ... you are right :D


On Feb 10, 12:45 pm, mariyan nenchev <nenchev.mari...@gmail.com>
wrote:

mariyan nenchev

unread,
Feb 10, 2010, 8:35:11 AM2/10/10
to google-we...@googlegroups.com
Hi, i tried it but it didn't work.
HTML text = new HTML("Reference : <a href="http://www.google.com">Help Desk</a>");

It still does not render as link...

mariyan nenchev

unread,
Feb 10, 2010, 8:38:53 AM2/10/10
to google-we...@googlegroups.com
OK, my fault it worked!
Message has been deleted

Daniele

unread,
Feb 10, 2010, 8:38:19 AM2/10/10
to Google Web Toolkit


Hi try to this

HTML text = new HTML("Reference : <a href='http://

www.google.com'>Help> Desk</a>");

I changed " with '
Cheers

tuxinoo

unread,
Feb 10, 2010, 12:57:48 PM2/10/10
to Google Web Toolkit
Why do you not just simply use Anchor widget ?

Sample: Anchor anchor = new Anchor("GWT Tutorials", "http://
www.gwttutorials.com", "_blank") ;

On 10 fév, 14:38, Daniele <der...@gmail.com> wrote:
> On Feb 10, 2:35 pm, mariyan nenchev <nenchev.mari...@gmail.com> wrote:
>
> > Hi, i tried it but it didn't work.
> > HTML text = new HTML("Reference : <a href="http://www.google.com">Help
> > Desk</a>");
>
> > It still does not render as link...
>
> Hi try to this
>

> HTML text = new HTML("Reference : <a href='http://www.google.com'>Help> Desk</a>");
>
> I changed " with '
> Cheers

philippe

unread,
Feb 11, 2010, 10:48:35 AM2/11/10
to Google Web Toolkit
Normally, Anchor is used to internal link. http://myapp/#myAnchor

On 10 fév, 18:57, tuxinoo <claudio.dossan...@gmail.com> wrote:
> Why do you not just simply use Anchor widget ?
>

> Sample: Anchor anchor = new Anchor("GWT Tutorials", "http://www.gwttutorials.com", "_blank") ;

Thomas Broyer

unread,
Feb 12, 2010, 12:06:49 PM2/12/10
to Google Web Toolkit

On Feb 11, 4:48 pm, philippe <philippe.vonc...@gmail.com> wrote:
> Normally, Anchor is used to internal link.http://myapp/#myAnchor

You're confusing Anchor with Hyperlink (or InlineHyperlink)

Christian Goudreau

unread,
Feb 12, 2010, 12:14:28 PM2/12/10
to google-we...@googlegroups.com
Anyway :

<g:HTMLPanel>
  blablabla your text <g:InlineHyperlink>Your link</g:InlineHyperlink> blabalbla your text
</g:HTMLPanel>

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.


Reply all
Reply to author
Forward
0 new messages