A small tool that allows you to edit multiple questions automatically (for example, add/remove answers numbering, etc.).
It works as follows:
- GET the list of questions in HTML format
- extract question data from the HTML form (yeah, "parsing HTML with regex is a bad idea" yada yada yada..., but who cares?)
- modify form data obtained on previous step in some way
- make POST request with modified data
It took me several days of reverse engineering. I can't count how many times stupid Moodle refused to accept my requests and just responsed with the same unchanged question page. NO ERRORS AT ALL!!! Fortunately, now it works!