Php photo gallery TWG | JFUploader | TWG Flash upload | WFU | Forum

Get help for TinyWebGallery, the best image gallery. The forum is also home for the Joomla JFUploader, TWG Flash Uploader and the Wordpress flash uploader.
It is currently 22. Nov 2024, 22:31

This forum is readonly now. Please use the new forum if you don't find the answer to your question here. The new forum is at https://www.tinywebgallery.com/blog/forum/


All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 30 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: 4. Apr 2017, 20:51 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
Hi!

I'm having a bit of an issue. My site (http://www.hafdal.dk/legstadaleit/) is starting to pop up in Google searches, but the problem is that the link that people are getting sent to is the content of the iframe and that is not embedded into the site like I want it to.

An example is:
The page displayed correctly:
http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is&page=www.hafdal.dk%2Ftng%2Fgetperson.php%3FpersonID%3DI4259%26tree%3DTree2

The iframe displayed on its own (which I do NOT want):
http://www.hafdal.dk/tng/getperson.php?personID=I4259&tree=Tree2

Any idea how I can fix this?


Top
 Profile  
 
PostPosted: 7. Apr 2017, 10:18 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
You need to use the external workaround script. Then you can configure that if the page is opened directly it is redirected to the main page.
You find this on the "external workaround" tab.

See:
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/change-links-targets#e11

var iframe_redirect_url = "http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo";

Best, Michael


Top
 Profile  
 
PostPosted: 15. Apr 2017, 22:16 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
Hi again.

My WP domain is: http://www.hafdal.dk/legstadaleit/
And my iframe domain is: https://www.hafdal.dk/tng/

Do I have to add the script like it says in Example 11 or is Example 10 enough for me?

Thanks!


Top
 Profile  
 
PostPosted: 16. Apr 2017, 08:49 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
You need 11 because in ai_external.js is the code for the redirect.

Best Michael


Top
 Profile  
 
PostPosted: 16. Apr 2017, 18:39 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
My current code looks like this:
Code:
[advanced_iframe securitykey="xxxx" use_shortcode_attributes_only="true" src="http://www.hafdal.dk/tng/cemeteries.php"  id="legstadaleit" height="800" width="100%" map_parameter_to_url="page"  add_iframe_url_as_param="same" onload_resize="true"]


And the script looks like this:
Code:
<script>
var iframe_redirect_url = "http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo";
var change_iframe_links = "#iframe-navigation a";
var change_iframe_links_target = "_blank";
</script>
<script src=”http://www.hafdal.dk/legstadaleit/wp-content/plugins/advanced-iframe/js/ai_external.js”></script>


But what should be in the script instead of "http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo"? And is that the only change I have to make before adding it to a page?


Top
 Profile  
 
PostPosted: 18. Apr 2017, 15:40 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
For your setup you only need.

[advanced_iframe securitykey="xxxx" use_shortcode_attributes_only="true" src="http://www.hafdal.dk/tng/cemeteries.php" id="legstadaleit" height="800" width="100%" onload_resize="true"]

<script>
var iframe_redirect_url = "http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is&page=www.hafdal.dk%2Ftng%2Fgetperson.php%3FpersonID%3DI4259%26tree%3DTree2";
</script>
<script src=”http://www.hafdal.dk/legstadaleit/wp-content/plugins/advanced-iframe/js/ai_external.js”></script>

var iframe_redirect_url is your parent url!

Best, Michael


Top
 Profile  
 
PostPosted: 18. Apr 2017, 16:17 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
Thank you very much Michael. I only have one last question (I hope), what file to I place the script in?


Top
 Profile  
 
PostPosted: 18. Apr 2017, 16:47 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
http://www.hafdal.dk/tng/getperson.php

So normally a footer file which is included everywhere...

Best, Michael


Top
 Profile  
 
PostPosted: 19. Apr 2017, 18:08 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
Hi Michael

I have now added:

Code:
<script>
var iframe_redirect_url = "http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is";
</script>
<script src=”http://www.hafdal.dk/legstadaleit/wp-content/plugins/advanced-iframe/js/ai_external.js”></script>


To my www.hafdal.dk/tng/footer.php file

I have also added the following to my WP page:

Code:
[advanced_iframe securitykey="xxxxxx" use_shortcode_attributes_only="true" src="http://www.hafdal.dk/tng/cemeteries.php" id="legstadaleit" height="800" width="100%" onload_resize="true"]


But going to f.ex. http://www.hafdal.dk/tng/showmedia.php?mediaID=2509&medialinkID=5056 does not redirect to http://www.hafdal.dk/legstadaleit/database/?page=www.hafdal.dk%2Ftng%2Fshowmedia.php%3FmediaID%3D2509%26medialinkID%3D5056

What am I doing wrong?


Top
 Profile  
 
PostPosted: 19. Apr 2017, 23:11 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
<script src=”http://www.hafdal.dk/legstadaleit/wp-content/plugins/advanced-iframe/js/ai_external.js”></script>

gives me a 404! so this you should fix first!

you use ” and not " !!

And why should it redirect to
http://www.hafdal.dk/legstadaleit/database/?page=www.hafdal.dk%2Ftng%2Fshowmedia.php%3FmediaID%3D2509%26medialinkID%3D5056

if you set
var iframe_redirect_url = "http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is";

?

Best, Michael


Top
 Profile  
 
PostPosted: 20. Apr 2017, 17:07 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
My code is now:

Code:
<script>
var iframe_redirect_url = ”http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is”;
</script>
<script src=”http://www.hafdal.dk/legstadaleit/wp-content/plugins/advanced-iframe/js/ai_external.js”></script>


I didn't notice that I had the wrong type of ", I just switched to Linux and my keyboard layout must be different.

The second part you write:

Quote:
And why should it redirect to
http://www.hafdal.dk/legstadaleit/database/?page=www.hafdal.dk%2Ftng%2Fshowmedia.php%3FmediaID%3D2509%26medialinkID%3D5056

if you set
var iframe_redirect_url = "http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is";


I don't quite understand what it should be instead of http://www.hafdal.dk/legstadaleit/gagnagrunnur/?lang=is - should it not be the basic url?


Top
 Profile  
 
PostPosted: 20. Apr 2017, 17:43 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
you still use ”

you need to use normal "

and you need to put in the url of the parent. the page where you want to redirect to.

press f12 to see the Javascript errors
ai_external.js%E2%80%9D Failed to load resource: the server responded with a status of 404 (Not Found)


Top
 Profile  
 
PostPosted: 20. Apr 2017, 18:01 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
I think I have it correct now, I can't see any errors at least.


Quote:
and you need to put in the url of the parent. the page where you want to redirect to.


But the problem is I want to redirect to different pages, I want to redirect all the pages in www.hafdal.dk/tng to open to in the iframe in www.hafdal.dk/legstadaleit. Maybe I have misunderstood what is possible?

For example:
This page:
http://www.hafdal.dk/tng/getperson.php?personID=I4042&tree=Tree2

Should be redirected to this page:
http://www.hafdal.dk/legstadaleit/database/?lang=is&page=www.hafdal.dk%2Ftng%2Fgetperson.php%3FpersonID%3DI4042%26tree%3DTree2


Top
 Profile  
 
PostPosted: 20. Apr 2017, 22:19 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
Then you define the
var iframe_redirect_url
at each file and the ai_external in the footer.php.

Best, Michael


Top
 Profile  
 
PostPosted: 20. Apr 2017, 22:28 
Offline

Joined: 15. May 2016, 21:44
Posts: 78
That is not possible :|

If I just want to redirect to http://www.hafdal.dk/legstadaleit/?lang=is, which is the frontpage of my website, is it then enough to have this script in the footer:

Code:
<script>
var iframe_redirect_url = ”http://www.hafdal.dk/legstadaleit/?lang=is”;
</script>
<script src="http://www.hafdal.dk/legstadaleit/wp-content/plugins/advanced-iframe/js/ai_external.js"></script>


So going to this page: http://www.hafdal.dk/tng/getperson.php?personID=I4042&tree=Tree2 will send me to http://www.hafdal.dk/legstadaleit/?lang=is.

Best regards
Rakel


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 30 posts ]  Go to page 1, 2  Next

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 34 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
powered by phpbb | Datenschutz/ Privacy policy