Notifications
Clear all

How do I make links work so they open in the iframe?

11 Posts
3 Users
0 Reactions
1,794 Views
Posts: 16
 xega
Topic starter
(@xega)
Eminent Member
Joined: 3 years ago

Hi

My setup is like this:

  • I have my WP installation in a folder (wp) off the root (www.legstadaleit.com/wp)
  • I have my iframe content (what I want to appear in the iframe) also in an iframe off the root (www.legstadaleit.com/tng)

My current shortcode is like this:

[advanced_iframe use_shortcode_attributes_only="true" src=" removed link " width="100%" height="600" onload_resize="true"]

And that works perfectly if I f.ex. put it in a page.

BUT....when I link directly to a page that is in the tng folder, like f.ex. removed link ;tree=, it opens outside the iframe.

I have looked at your examples, but unfortunately I don't understand how I should set my links up so that they open within the iframe.

If you go to f.ex. removed link and click on one of the photos of the men there, you can see exacly what I mean.

I hope you can help!
Best regards
xega 

 

10 Replies
TinyWebGallery
Posts: 925
Admin
(@admin)
Prominent Member
Joined: 16 years ago

the links are removed as you are a new user. 

Please see: http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/change-links-targets#e10

There you see how you can modify links targets dynamically.

Best regards, Michael

Reply
1 Reply
 xega
(@xega)
Joined: 3 years ago

Eminent Member
Posts: 16

@admin hi Michael m. Like I wrote in my original post, I don’t understand the example. Can you give me a hint at least how I should do this?

Reply
Posts: 16
 xega
Topic starter
(@xega)
Eminent Member
Joined: 3 years ago

Hello again.

I have purchased support now. I really hope you can help me fix this soon, my website depends on this working.

Best regards

Rakel

Reply
TinyWebGallery
Posts: 925
Admin
(@admin)
Prominent Member
Joined: 16 years ago

Hi,

what is your problem? changing all links by using "a" as parameter should work fine if you are on the same domain.

Best Michael

Reply
Posts: 16
 xega
Topic starter
(@xega)
Eminent Member
Joined: 3 years ago

Hi Michael, sorry for the late reply. 

I think I was not doing this iframe thing correctly. Previously I had made an wp page with an iframe for each page I wanted to display on my webpage. But then I realized that was not a sensible thing, so I just created one page with the iframe content.

I also figured out how to add the iframe url to the wp url so now it is possible to bookmark content within the iframe. I think that has mostly solved my problem since I investigated the issue and found (am I correct?) that google will not index the iframe content directly but indexes the iframe content inside the wp content like it should be. That means that search results will give links that show the full content, both the wp and the iframe inside. So maybe I don't need this functionality after all?

My shortcode now looks like this (do I need "https" in the scr?):

[advanced_iframe use_shortcode_attributes_only="true" src="//www.legstadaleit.com/tng/searchform.php" width="100%" height="600" onload_resize="true" map_parameter_to_url="iframe" add_iframe_url_as_param="same"]

I have however encountered a new "issue" and that is how do I track the traffic inside the iframe f.ex. with Google Analytics or Matomo Analytics? As soon as a user clicks the webpage that has the iframe, it stops tracking it seems. 

I hope you can help me with these questions.
Best regards

Rakel

Reply
Page 1 / 2