Php photo gallery TWG | JFUploader | TWG Flash upload | WFU | Forum
https://www.tinywebgallery.com/forum/

Add custom field to src
https://www.tinywebgallery.com/forum/viewtopic.php?f=21&t=4435
Page 1 of 1

Author:  teracomp [ 21. Sep 2017, 11:55 ]
Post subject:  Add custom field to src

Is it possible to add a custom field, e.g., Advanced Custom Fields, to the src attribute?

For example, [advanced-iframe securitykey="111222333444" src="http://www.baseurl.com/token/dd1-8874-sP3dCial"]

The intent is for the src (external workaround in place) to parse the token and customize the user experience.

For the site in question, I have six different pages, each will have a unique token, but the base URL will be the same.

Author:  TinyWebGallery [ 21. Sep 2017, 13:03 ]
Post subject:  Re: Add custom field to src

The post meta data is not read. But if you have 6 different pages can you not simply add this to the src url directly?

Best, Michael

Author:  teracomp [ 21. Sep 2017, 16:37 ]
Post subject:  Re: Add custom field to src

The token that is passed includes the user's id so the app knows what content to deliver. It needs to know who the user is in order to configure itself correctly.

Author:  TinyWebGallery [ 21. Sep 2017, 16:45 ]
Post subject:  Re: Add custom field to src

the user id is available. See the documentation in the administration of the src field.

See http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/url-features#h49

Best, Michael

Author:  teracomp [ 21. Sep 2017, 17:06 ]
Post subject:  Re: Add custom field to src

Sweet!

//www.test.com/{userid,none}

This will be amazing to see in action!!

Thanks!

Author:  teracomp [ 21. Sep 2017, 18:02 ]
Post subject:  Re: Add custom field to src

I now understand parameters...that is a great feature!

However, one problem:
Refused to display 'http://xxxxxxxx/app/token/3' in a frame because it set 'X-Frame-Options' to 'deny'.

xxxxxxx == my app's site
3 == my userid, so it's getting parsed correctly.

The app site is not on the same server.

Author:  teracomp [ 21. Sep 2017, 18:15 ]
Post subject:  Re: Add custom field to src

Disregard the last post about X-Frame-Options. I'm pretty sure it's my mistake. When I removed /token and simply added the {userid,none} param the iframe displays.

In other words:

WORKS: src="http://basesite.com/hm5/app/{userid,none}"

FAILS: src="http://basesite.com/hm5/app/token/{userid,none}"

The reason is on my app end.

Thanks for your patience and rapid responses!

GREAT SUPPORT!

Author:  TinyWebGallery [ 24. Sep 2017, 21:05 ]
Post subject:  Re: Add custom field to src

Great ;).

Page 1 of 1 All times are UTC + 1 hour [ DST ]
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/