Do you by any chance know where I can get a list of all these variables which are passed to header.html and which I could make use of?
It would indeed be nice to have a list with some useful variables, but it would be impossible to make this list exhaustive. current_theme()
is just one of Moodle's many functions. Basically every Moodle function can be included:
<?php if (isadmin()) {
<?php if (!isguest()) {
<?php if (isteacherinanycourse()) {
etc...
It's a pity Moodle's core API hasn't been updated for a while. That was a very useful resource to find out which functions provide info about courses / users / etc...
A lot of information about the logged in user is stored in a global called $USER. To find out what is in there, you can dump the content of this user at the end of the page, by adding
<pre><?php var_export($USER);?> </pre>
to the file footer.html of your testinstallation. I noticed there was some information about teacher / student status stored inside. Maybe you could use the same trick to find out about other variables: $CFG also stores a lot of information that may be useful for themes.