We have implemented magnific pop-up to our website for internal links only. When a user clicks from an external link (i.e. Facebook, Google) we would like to load it without the pop-up. In fact there is a second template besides the one with the magnific pop-up for the same content (article) especially for this (external links). However when a user clicks an external link (direct link to the content) it first loads the content without the pop-up and on top of that it loads again the content with the pop-up. How can we eliminate the on top second loading for external links?
Example page
Related
I have a webpage hosted in Firebase that loads content from another HTML page inside a div upon clicking a link using:
$('#div').load(url);
The problem is that this method does not change the URL for the page so it is uniquely identified. Is there a way to make it so that when running that command it changes the URL so that the user can bookmark the page, and when that page is loaded it recreates the page with the loaded HTML?
I want to create a google extension that shows a pop-up dialog when a specific page is loaded (e.g. stackoverflow.com).
Is that possible? If so, how?
In facebook feed or Pinterest gallery, when a user click on the content, jQuery will load the content and appended it to the current page as a modal (the url of browser will also changed according to a.href, even though there's no page reload). However, if the user launch a new page with the very same url, he is going to see a page with different layout (as opposed to the modal's) but the same content.
How do I accomplish this? (a click will load content onto a modal, while launch url as new window will display content on a new page with different layout)
I want to open a remote url inside a javascript popup instead of doing window.open().
I came across libraries like lytebox,lightbox,thickbox which do that if the popup is opened from main webpage.
However my requirement is to open the popup from the link which occurs in a small iframe within the main page.( I can not alter the code of the main page, however Iframe webpage is fully in my control)
When I include those libraries in my iframe webpage, it opens the popup, but restricted only
to within iframe.How to make it appear over whole browser window ?
This is what i want : The user clicks on "click here" and it opens a javascript layer,not
restricted to within iframe.
you can just use
parent.document
from the iframe to access the parent window, if it is from the same domain. Otherwise, security concerns are raised.
You can inject the javascript by creating a script element in the parent's document, and then will be able to access the necessary functions.
I'm including a page on my site with an iframe. The page in the iframe has the functionality to open a lightbox, which now of course opens in the iframe itself.
Is there a possibility that the iframe content opens the lightbox on the top frame? (On the page that includes this iframe)
if it's opening via javascript, use
window.top.location = "http://destination-url.com";
if it's a anchor link, then add
target="_top":