-
Notifications
You must be signed in to change notification settings - Fork 445
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Let iframe use relative URL instead of absolute #6246
Comments
@sean-xiao-zhao7, please do! |
…marty so EZProxy installs can see the URL and rewrite it (if they use a DomainJavascript directive). Fixes #34.
… so EZProxy installs can see the URL and rewrite it. (EZProxy config will need a DomainJavascript directive for this). Fixes #34.
… so EZProxy installs can see the URL and rewrite it. (EZProxy config will need a DomainJavascript directive for this). Fixes #34.
…roxy rewriting. (Remote) EZProxy config will need a DomainJavascript directive for this. Fixes #34.
…rewriting. (Remote) EZProxy config will need a DomainJavascript directive for this. Fixes #34.
…rewriting. (Remote) EZProxy config will need a DomainJavascript directive for this. Fixes #34.
Merged manually for release in OJS and OPS 3.2.1-2; ported to OMP for release in 3.2.1-2. |
Thanks, @sean-xiao-zhao7! |
Hi Everyone! Happy New Year! 🎉 I'd like to add to this conversation in 2021 because a journal subscriber last week opened a ticket about urls breaking again due to EZProxy. We found that the merged solution in this thread was not enough to solve it. I would like to add our additional solution at (UofT Libraries) included modifications to the javascript in the/pdfJsViewer/templates/display.tpl template file. In order for this change to be enabled across the board, the display.tpl file had to be replaced in all our themes that used pdfJsViewer/templates/display.tpl. As per your readme, I didn't want to open another issue, so do let me know what's the procedure if I'd like to contribute to an older issue that's reappeared. Many thanks to the original developers who provided the solution. For context, I'm now Sean's successor at (UofT Libraries), so happy to contribute to the solution once again. Thank you, take care and stay safe.
|
+1 for @wangra8 's fix. This was timely - I confirm that this solved an exProxy issue with a hosted client this morning. |
Good to hear that this is helpful for 2 different installs, but I'm confused about why EZProxy isn't rewriting the URLs where they're declared with the JS |
Hi Everyone! 👋 I'm glad to hear it helped solve the issue for someone else too. 😃 I'm afraid I don't have the root cause about why EZProzy suddenly stopped rewriting the URLs, but we know that the user which reported the issue, updated their EZProxy which then broke the URLs. We ruled out ojs upgrade breaking this because our last upgrade was to 3.1.2 was in November 2019. When this broke, iframes started looking like this, so we went with the quickest solution possible which was to rewrite it manually with javascript. I'm open to a more elegant solution, for now we have deployed this into production to keep this from happening again to our users. Thank you and stay safe! Update: Oops, forgot to ask, should I open a new issue and create a PR? --Rachel
|
Thanks, @wangra8, that helps. So it sounds like an EZProxy update caused the change in behaviour? What was the previous version of EZProxy, and what are you using now? |
Hi @asmecher & Everyone! 👋 Sorry I have to retract my statement that EZProxy update was the root cause. I haven't worked with this particular functionality of OJS too much so I went back and checked in with my awesome team members 😄 🌟 and these are the pieces of information I'm going to share. 🤓 📖 At the end of the Iter Stanza file the following worked fine.
Then in the past few months a different resource that we proxy introduced this line into EZP's config.txt
I hope this makes the root cause clearer, let me know, I will do my best to answer! Thank you & stay safe! ---Rachel |
New issue filed here --> pkp/pdfJsViewer#60 |
See https://forum.pkp.sfu.ca/t/pdf-js-viewer-fails-when-proxied-fix-and-solution/18257
The current iframe URL does not work with EZProxy setups.
EZProxy is unable to correctly calculate the base URL - it always seems to use the non-ezproxyed base URL.
After discussion with Clinton Graham, we've came up with a solution.
I'd like to submit a PR on this repo for this fix.
The text was updated successfully, but these errors were encountered: