Giter VIP home page Giter VIP logo

Comments (9)

C0D3D3V avatar C0D3D3V commented on August 22, 2024

For me the quizzes still looks fine. (only some resources are missing, but not the font that is missing in your image) Maybe your browser does not allow cros origin requests. You can send me your HTML if you want. Maybe try to open your HTML in Chrome since it has less strict CROS rules than Firefox.

Interestingly, the flag image that is showing in your image is missing for me, but the font is loaded :D

Yes, I used the moodle of RUB because it is a big University in Germany and I guess they will leave the moodle for long time on that domain. It was the simplest option for me, because creating an own styling or copying the styling of moodle app is a lot of work.

We have some options:

  • update to the new styling of RUB moodle so there are no more missing resources.
  • host the missing resources on github, change the href to github
  • copy the style of moodle mobile app, and embed every needed resource using base64
  • create an own styling that does not use any online resources so that you can view everything also offline

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on August 22, 2024
  • correcting myself - even the flag image is shown, that is part of the downloaded quiz and is included via href -> my testing moodle instance was only down, thats why it was not shown.

So for me everything is still correctly displayed :D

But I would also love to have a clean simple own CSS.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on August 22, 2024

And strict cross origin is a problem indeed. A clean css where everything is included in the HTML would be the best.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on August 22, 2024

For the record. The moodle mobile app uses these ionic angular templates to build the html:

https://github.com/moodlehq/moodleapp/blob/97856e457a84d9b74bd320def97715b75eedc5ce/src/addons/mod/quiz/pages/review/review.html
https://github.com/moodlehq/moodleapp/blob/97856e457a84d9b74bd320def97715b75eedc5ce/src/core/features/question/components/question/core-question.html

(and a lot more more (for every addon question type one), see the source)

And the question helper contains most functions to build the Components, and extract and build the needed js
https://github.com/moodlehq/moodleapp/blob/97856e457a84d9b74bd320def97715b75eedc5ce/src/core/features/question/services/question-helper.ts
https://github.com/moodlehq/moodleapp/blob/97856e457a84d9b74bd320def97715b75eedc5ce/src/core/features/question/classes/base-question-component.ts#L454

Also there are many more questiontypes...
https://github.com/moodlehq/moodleapp/blob/97856e457a84d9b74bd320def97715b75eedc5ce/src/addons/qtype/qtype.module.ts

I do not think it is a good Idea to copy all this into moodle-dl or even to call the ionic from python to generate the html. Thats seems out of scope for moodle-dl

Also this indicates how complicated it would be to build an own styling.

I will think about a solution that could work, with minimal effort.

from moodle-dl.

daniarla avatar daniarla commented on August 22, 2024

So for me everything is still correctly displayed :D

fyc

For me it does not matter what browser I use I can not get all the images.

I will think about a solution that could work, with minimal effort.

Maybe the simple solution is not using an html at all? I can live with simple markdown file as long as I can get all the info.

Also there are many more questiontypes...

Yeah.... Seems like a lot of work to implement something for each one :(

If you want, I can send you the html, I think I have your email somewhere

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on August 22, 2024

Simplest solution for now is, to include the css into the HTML, and fix the font by using a CDN or import it with base64 (so you could also view it without internet).

And we do not care about all the javascript problems for now until someone finds a new problem :D

We can not use some other moodle instance since now all moodle instance on latest version use the same side cross origin, (we could only use an outdated instance, but somday it will be updated) and do no longer allow cross origin from other domains (like local) .

P.S. Creating a good readable markdown is not that simple. Its as readable as if you remove the Style from the HTML, and you will not see the question correctly, since we can not display checkboxes and other stuff, like textboxes, drag and drob questions.....

I would stick with HTML, but fix it somehow.

from moodle-dl.

daniarla avatar daniarla commented on August 22, 2024

P.S. Creating a good readable markdown is not that simple. Its as readable as if you remove the Style from the HTML, and you will not see the question correctly, since we can not display checkboxes and other stuff, like textboxes, drag and drob questions.....

I didn't think about that, makes sense.

I would stick with HTML, but fix it somehow.

Good call. 👍

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on August 22, 2024

Fixed Quizz Header And Footer.zip

I pin this file here just that I can find it if we need it in the future.

I will solve the problem for now, just by fixing the font problem. (that will only add like 10 lines to the html)
Fixing all other problems, (that may already exists, but we cant tell. because we have no test data) we will do on demand. For that we probably need to include all the files as I did in the uploaded Fixed Quizz Header And Footer.html

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on August 22, 2024

Please test the latest version, if you have more problems with Quizzes HTMLs, please report them in new issues.

from moodle-dl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.