Supporting each other

Community forums

Welcome, Guest
Username: Password: Remember me
This is the place for questions about learning design and pedagogy; how to use different page types for different purposes.
  • Page:
  • 1

TOPIC:

PDF page customisation and affect to the Xerte when version upgrade installed 3 years 2 weeks ago #7250

  • annem
  • annem's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
  • Posts: 178
  • Thank you received: 0
Hi all,
Re: PDF with customisation code, and the impact and affect to those Xerte projects with PDF customised code when there is a version update installation.

Installation of version 3.8.5 provided a PDF link available which is available by default. Providing guidance to end-users to make sure that they know that Xerte remains available after clicking on the Open PDF link can be written and instruction on how to continue the Xerte e-learning (because depending on browser, VLE and Xerte export option, it can seem to the end-user that Xerte has closed).

After I posted on the forum i was provided with helpful guidance and advice.
Xerte forum Open PDF guidance

So I go a step further, based on the feedback I received from the forum, by adding code to the PDF page type to make the PDF page better for the end-user.

I turn on Show Language options and change the link text to something like: Open PDF (opens in a new tab).
Add the following code:
Use script and css to open the pdf link in a lightbox:
//add the following to a script optional property
$("#pdfLink").attr("data-featherlight", "iframe");

/*add the following to a styles optional property*/
.featherlight iframe {
height: 90vh;
width: 90vw;
}

What happens to these Xerte projects when a version upgrade is installed?

I look forward to hearing from you.
Best wishes
Anne

Please Log in or Create an account to join the conversation.

PDF page customisation and affect to the Xerte when version upgrade installed 3 years 2 weeks ago #7252

  • Fay
  • Fay's Avatar
  • Offline
  • Elite Member
  • Elite Member
  • Posts: 231
  • Thank you received: 86
Hi Anne. This should be fine and continue to work after upgrades. The main danger with customising Xerte and then upgrading is when the customisation is done directly in the page model files rather than in individual projects. If you do this then every time you upgrade, the page model file will be overridden with the updated version and you need to add the customisation back in. In your case the info is held in the project data and won't be touched by upgrades. Your custom code references a link with an id of 'pdfLink' - if the name of this element was changed in the page model file in an upgrade then your code would stop working but we try to avoid doing this where possible as changing the names of elements can have an affect on lots of other things (e.g. themes).
Fay

Please Log in or Create an account to join the conversation.

PDF page customisation and affect to the Xerte when version upgrade installed 3 years 2 weeks ago #7255

  • annem
  • annem's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
  • Posts: 178
  • Thank you received: 0
Hi Fay,
Thank you so much for the reply which has reassured me. Looking forward to virtually meeting you at the Xerte Conference.
Keep safe and well. Best wishes. Anne

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Moderators: ingdon
Time to create page: 0.060 seconds
Copyright © 2024 The Xerte Project.
Xerte logo Apereo logo OSI Logo

Search