jquery-powertip icon indicating copy to clipboard operation
jquery-powertip copied to clipboard

Doesn't work on multiple pages in iframe

Open GinoPane opened this issue 1 year ago • 2 comments

My app is an embedded one and is displayed in iframe.

And Powertip only works on initial page load. When I move to another page and then move to the initial one, tooltips are no longer showing.

Init code runs just fine, but does nothing. Powertip->destroy with further init also does nothing.

Only full page reload helps, but it is not a solution.

GinoPane avatar Dec 15 '23 07:12 GinoPane

A couple requests:

  1. What browser are you using? Can you test a different one?
  2. Can you provide some example code me to test?
  3. Can you clarify what you mean by "move to another page"?
    • Do you mean click a link on the page embedded in the frame?
    • Or, do you mean click a link on the parent page which has the actual <iframe> tag?
    • Or, do you mean something else? Like manually entering a URL of another website in the browser then going back to the <iframe> page? Or switching to another browser tab?

I ask because I cannot reproduce this problem. It seems to work for me in Firefox and Chromium. Here is the <iframe> test page that I used to check:

iframe-test.html

<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8" />
	<title>PowerTip iframe Test</title>
</head>
<body>
	<h1>PowerTip <code>&lt;iframe&gt;</code> Test</h1>
	<iframe width="800" height="600" src="https://stevenbenner.github.io/jquery-powertip/"></iframe>
</body>
</html>

stevenbenner avatar Dec 16 '23 16:12 stevenbenner

  1. What browser are you using? Can you test a different one?

It was the latest Chrome, but the same issue was in other browsers

  1. Can you provide some example code me to test?

The code with powertip usage is just purely basic, init on page load and that's it.

  1. Can you clarify what you mean by "move to another page"?

Yes, I assume the reason would be here somewhere. So basically the application is running as embedded application in the Shopify admin. So the admin works by itself and it serves an iframe, where the application page is displayed. "move to another page" in this sense means that technically browser stays on the same Shopify admin page, but the iframe contents (e.g. application) gets updated.

GinoPane avatar Dec 28 '23 14:12 GinoPane