Report any technical problems you discover and discuss solutions.

session expired error

  • teacherjonny
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 years 4 weeks ago #9112 by teacherjonny
session expired error was created by teacherjonny
Here is an example of a simple code snippet that, in Xerte, will produce a error popup that says that my session has expired. Almost every time I use the script box I het that error. Here is some code that runs without a problem in a browser:
<!DOCTYPE html>
<html>
<body>

<button onclick="playVid()" type="button">Play Video</button>
<button onclick="pauseVid()" type="button">Pause Video</button><br>

<video id="myVideo" width="320" height="176"autoplay="true">
<source src=" essentialhebrew.com//xrtAssets/video/snowy_owl.mp4 " type="video/mp4">

Your browser does not support HTML5 video.
</video>

<script>
let vid = document.getElementById("myVideo");

function playVid() {
vid.play();
// alert(vid.duration);
}

function pauseVid() {
vid.pause();
}
</script>



</body>
</html>
Thank.

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

More
2 years 4 weeks ago #9113 by tom
Replied by tom on topic session expired error
Hi,

What exactly do you put in the script box?
The following user(s) said Thank You: teacherjonny

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

  • teacherjonny
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 years 4 weeks ago #9114 by teacherjonny
Replied by teacherjonny on topic session expired error
Here's what I put in the script box:
let vid = document.getElementById("myVideo");

function playVid() {
vid.play();
// alert(vid.duration);
}

function pauseVid() {
vid.pause();
}

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

Moderators: ronmjultenJohnSmith
Time to create page: 0.138 seconds
Copyright © 2026 The Xerte Project.
Xerte logo Apereo logo OSI Logo