Hi Thomas,

according to Mariyan's description, the words should be embedded in
the text, so I assume, that they should look like links (color,
underline) and feel like links (mousepointer, ...) I would find it a
little bit odd to use spans, only to redecorate them using CSS to make
them look like hyperlinks. From the user's perspective, they should
work like hyperlinks - the use case basically doesn't change, if the
action is executed by a request to the server side or not. (Also,
there have always been in-page links "#...", so not every link has to
create a request to the server.)

Of course, it's also ok to use spans, actually they can be used for
everything in an HTML page, as long as CSS is enabled, so... raises
the question what HTML is good for anyway.

Chris


On Mar 4, 4:38 pm, Thomas Broyer <[email protected]> wrote:
> On Mar 4, 3:30 pm, Chris Lercher <[email protected]> wrote:
>
> > If you're browsing this newsgroup via the web interface (http://
> > groups.google.com/group/google-web-toolkit/browse_thread/thread/
> > a393ba8235e414da/fa97b262f15e245d#fa97b262f15e245d), then try to click
> > on the hyperlink called 'Options' (top right corner), and you'll see
> > for yourself!
>
> ...and that's clearly an abuse of a <a> HTML element as it's more a
> "button" than a "link"; but that's another debate.
>
> @mariyan: use an HTML widget and markup your words (using e.g.
> <span>Google</span>), then in your ClickHandler, you can query the
> NativeEvent and from it the actual event's target. If the target
> element's tag name is "span" (preferably case insensitive) then you
> can look at its content or some attributes or... (if you need "custom
> attributes", I suggest using the data-* prefix as "suggested" by
> HTML5, e.g. <span data-word="google">Google</span> and then in your
> code: elt.getAttribute("data-word"))

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

Reply via email to