Can i capture URL parameters?

Does ActivePresenter support capturing URL parameters?


Do you mean that getting parameters passed to the HTML5 player via the URL, such as test.html?param1=value1&param2=value2 ?


Yes, that would be awesome. Is there a guide to achieving this so that I can access these URL parameters as variables in ActivePresenter?

ActivePresenter supports some parameters (I use tutorial mode - tutorial.html as samples):

  • Link to a specific slide: tutorial.html?slide=N, where N is the slide index (starting from 1)
  • Link to a specific time in a slide: tutorial.html?slide=N&slidetime=AhBmCs, where N is the slide index and slidetime is in the time starting from the beginning of that slide.
    Example: tutorial.html?slide=2&slidetime=2m30s will link to slide 2, starting from 2 minutes and 30 seconds.
  • Link to a specific time (starting from the beginning of the presentation): tutorial.html?time=AhBmCs
    Example: tutorial.html?time=2m1s will link to 2 minutes and 1 second into the presentation.

For custom parameter, you need to use JavaScript. For example:

// url: ....tutorial.html?name=abc
// Note: this sample code doesn't work on IE browser
var url = new URL(location.href);
var name = url.searchParams.get('name');  // abc


1 Like

Is it possible to disable some of these default parameters?
I’m concerned about students skipping parts of the task.

No, it’s not possible to disable these default parameters.
If students skip parts of the task this way, they will not gain any scores for those parts. So I think you don’t need to worry about that.
You can also consider using an LMS which usually doesn’t allowing students to change the url.