Menu icon Foundation
Tooltips via AJAX Don't Work

Tooltips that are added to the DOM via AJAX don't work. I've tried the following JS calls after the AJAX function but they don't seem to solve the problem.

$(document).foundation();
$('#name-of-changed-div').foundation('tooltip');

This is with foundation 5.4.

AJAXtooltips

Tooltips that are added to the DOM via AJAX don't work. I've tried the following JS calls after the AJAX function but they don't seem to solve the problem.

$(document).foundation();
$('#name-of-changed-div').foundation('tooltip');

This is with foundation 5.4.

Rafi Benkual over 4 years ago

Have you tried reflow?

Reflow will make Foundation check the DOM for any elements and re-apply any listeners to them.

$(document).foundation('tooltip', 'reflow');

Zach over 4 years ago

Thanks Rafi. I had not tried that but I just did and I'm still having the same issue.