I am pretty sure that 'title' works in both IE and FireFox.  It seems like
for quite a while, people were using the 'alt' tags for this purpose.  They
only show mouse-over text in IE.

David.

On Jan 21, 2008 4:16 PM, Linda Rawson <[EMAIL PROTECTED]> wrote:

> I did this in the
>
> redraw:
> method of the panel.js itself with the following lines but it is a total
> hack and only for my application:
>
> var ctrlName = this.controls[i].CLASS_NAME.replace("OpenLayers.",
> "").replace("Control.","");
> var title = null;
>
> if (ctrlName == "ZoomBox") {
>   title = "Zoom to Location";
> };
> if (title != null) {
>   element.title = title;
> }
> this.div.appendChild(element);
> A title would be great as well as the ability to hide/show a control.
>
> My understanding is that this title attribute is only good in IE.
>
> Linda Rawson
> On Jan 21, 2008 2:33 PM, Gregor Mosheh <[EMAIL PROTECTED]> wrote:
>
> > This one sounded easer than it turned out to be. :)
> >
> > HTML elements can have a title attribute, and most browsers will show
> > that text when the mouse hovers over the element.
> >
> > How may I apply this to OL Controls? I tried a few of the more obvious
> > approaches, such as adding "this.div.title = 'Pan the map'" in
> > initialize() but to no avail.
> >
> > Is this non-trivial to do? Is a 'title' param something that would be
> > useful to add to Control itself for making a general solution to this?
> >
> > --
> > Gregor Mosheh / Greg Allensworth, BS, A+
> > System Administrator
> > HostGIS cartographic development & hosting services
> > http://www.HostGIS.com/ <http://www.hostgis.com/>
> >
> > "Remember that no one cares if you can back up,
> >  only if you can restore." - AMANDA
> > _______________________________________________
> > Users mailing list
> > [email protected]
> > http://openlayers.org/mailman/listinfo/users
> >
>
>
>
> --
> Linda Rawson
> _______________________________________________
> Users mailing list
> [email protected]
> http://openlayers.org/mailman/listinfo/users
>
>
_______________________________________________
Users mailing list
[email protected]
http://openlayers.org/mailman/listinfo/users

Reply via email to