Adding hover text to attribute table (too.long) attr doesn't ahow

adding this breaks the atrribute display on the legacy dashboard:

 if (hoverTextOnFirmwareAlerts)  myresults = myresults + "<tr><td><p title=\"${hoverstr}\">${name}</p></td><td>${df}</td></tr>"
            else myresults = myresults + "<tr><td>${name}</td><td>${df}</td></tr>"

this works without the paragraph with title..

i have to post it as a image as the html doesnt show here

any ideas thanks

both work fine on the device panel and the hover text is working there.

@gopher.ny

Bump @bobbyD

Perhaps take a step back and explain what you are wanting to achieve with the hover text... (and let's not discount something Smartly may have introduced... have you tried a "vanilla" dashboard?)

Bump.... :wink:
Dog Fist Bump GIF by merkinspurlock

1 Like

Yes tried regular dashboard. Just as the desc. I want hover descriptions on the field. Its not rocket science.

I'm not able to reproduce with a Virtual Omnisensor and the variable attribute set to this:

<table><tr><td><p title="test text">My paragraph</p></td></tr></table>

Demonstration of a tile with the variable attribute set as the attribute for an Attribute tile template:

Screenshot 2025-05-26 at 12.15.30

I would suggest paring your code down to a minimal example so you can figure out exactly what the problem is in your case, as the title attribute does not seem to be broken or problematic in general.

Considering that you posted on a Sunday and today, less than one whole day later, is a holiday in the US, where Hubitat is based, I would also give it a bit more time before you consider tagging/bumping your own post. (But I suspect you'll figure out something on your own with the above.)

1 Like

here is my just a regular dashboard


not a variable a custom attribute. not sure if that makes a difference,

all i get is this.. when i look at source

thats not relavant as it sppears in a dashboartd that works as well

that was in chrome.. just tested in explorer same issue

The variable attribute I mentioned above is a custom attribute on the device, not an actual variable. They should be the same. I think the best way to figure this out is to pare your code down to a minimal, non-working example so you can determine exactly what breaks it for you as I suggested above:

FWIW, I only tested in Firefox.

1 Like

it is minbimum.. its one table one attribute.. how do i actually see the page source,..,

ill pm you a link to the dashboard.

there is not much i can do .. its obviously not renedering correctly some issue inside hubitat the source does not show the attribute..

any other attribute works.

This can't be a minimal working example, as it is not complete code someone else can run. Create an app or driver (whatever your doing or can demonstrate the same thing) that sets an attribute to a value that breaks and does only that, nothing else. Then share that complete code here. Ideally, do this in a way where you gradually build on it to find the specific HTML that causes the problem. I suspect you'll discover something on your own this way, but if not, it will give someone else the best clues.

My HTML was a best guess based on the snippet I can see in your post. Even that can't be everything, otherwise you have malformed HTML (no table), though I tried it both ways and my browser didn't barf.

Is it the attribute itself or just the calie that's the problem?

1 Like

Also, thinking about this a bit more, you are using string interpolation. Have you verified that nothing getting put in uses characters that would be invalid at that point in the HTML? Testing with hardcoded strings (again, just to test) instead of whatever these values may be would be a good thing to test.

1 Like

yes here is test with actual data i printed out.. still shows fine on device panel but not in legacy db.

didnt find the issue

just for $hits and grins i took the minimal device driver i posted above and tried it on my other c8 pro in another location just in case something was corrupted in my local hub..

nope: same issue.. so either something is wrong in my code or there is some issue.

thanks again.

Thanks!

This sort of works for me:

Screenshot 2025-05-26 at 15.32.37

When it doesn't, this is the self-explanatory problem (the fact that above works is probably an artifact of the apparent design choice to only care about this on reload, not when the event itself happens -- I had the dashboard open at that moment and reloaded it at this one):

This isn't surprising giving how much data you are interpolating or concatenating into one attribute value.

I have no problems if I modify your example to consistently produce strings under this limit:

Code
    def name1 = "name1"
    def name2 = "name2" 
    def name3 = "name3"
        
    def time1 = "5 PM"
    def time2 = "6 PM"
    def time3 = "8 AM"
        
    def desc1 = "Desc1"
    def desc2 = "Desc2"
    def desc3 = "Desc3"
        
    def impact1 = "Impact1"
    def impact2 = "Impact2"
    def impact3 = "Impact3"
        
    def cond1 = "c1"
    def cond2 = "c2"
    def cond3 = "c3"
        
    
   def hoverstr1 =  "Con: $cond1, Des: $desc1, Im: $impact1"
   def hoverstr2 =  "Con: $cond2, Des: $desc2, Im: $impact2"
   def hoverstr3 =  "Con: $cond3, Des: $desc3, Im: $impact3"

One of my suggestions above was to have built up this string until it breaks; had you tried this, I suspect you would have discovered this yourself sooner. It's also a good idea to check Logs when something doesn't work as expected, as you'll likely find the same clue I did.

As for the actual issue, I suspect you'll have to either shorten your data or find some other way to display this information if needed (splitting the data among multiple attributes, hosting it at a local endpoint from an app you can manuever the dashboard into displaying somehow, etc.). Given the above, I don't see any demonstrated problem with Hubitat Dashboard or the title attribute as in the original question.

1 Like

Thanks it the boy who cried wolf ... I see that message all the time so just ignored it as it never really seemed to effect anything. I was looking for a message in the logs when setting the attribute not displaying the dash. Shame it works fine in the device panel.

Ill have to code it as 5 or 10 separate attributes but the nimber cannot be user selectable as it is now sigh.

Lol thanks for your help.