Moodle™ is a registered trademark.
Site policy | Contact
"text-align:left" "clear:both" etc. is not acceptable, even the JS enabled hiding should be done via classes
border:1px solid grey
Petr, the theme css loaded too late to hide some element, if I removed display:none from comment template div, the html code will be displayed until css loaded.
Are you talking about setStyle method call? Are you suggesting me hide/show element by change it by addClass/deleteClass? I don't think it is more reliable than setStyle.
no, we already have the "jsenabled" class hack (introduced by Tim I guess) which is executed very early on each page - all other code should use it.
document.body.className += ' jsenabled';
I am talking about the js template in comment/lib.php line 302, which should be hidden all the time, no matter js enabled or not
oh oh, that should be of course hidden always, sorry for not reading it properly
> even the JS enabled hiding should be done via classes
About this, I also need to check if the element is hidden, I cannot do this via classname, any class could have display:none attribute, use setStyle/getStyle is the most reliable way to do this? Do you agree?
yesterday I quickly looked at the template code use in comments, how is it supposed to work exactly? I thought that the comments are visually the same everywhere and the callbacks just change access control. What exactly may the plugins change?
modules have a callback to completely change the layout of comment entry, it can hide/show commenter name or comment date according module settings. and this is not controlled by theme.