Skip to content

Preset previously Selected Or Entered Value #192

@alaksandarjesus

Description

@alaksandarjesus

As as user, I answered a H5P question. When I refresh the page, the page does not show the previously selected value or previously entered value.

Is there a way to set the previously selected value.

I tried the below solution which I read through from the forum page


const instances = window.H5P.instances;
for (var i = 0; i < instances.length; i++) {
  const instance = instances[i];
    if (instance.showSolutions) {
      instance.showSolutions();
    }
}

But it says wrong answer was selected, which is not true. In this case, very dark purple is correct answer

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions