Blocks

Disappearing Moodle 2 blocks for site administrators

 
 
Picture of Barry Richards
Disappearing Moodle 2 blocks for site administrators
 

Hi,

I've got a weird inttermitent problem that has effected multiple sites. Blocks disappear en masse for site/school administrators when logged in. Guest users and pupils logged in can see the blocks without problem.

Looking through the HTML source I can see that the blocks are being output by the PHP code. However, something is causing the CSS to render them in such a way that they're not visible. I don't think a display:none rule is being applied, because the length of the page is effected, i.e. they're being shunted below the main content. Something is happening to the margins or padding of content to effect the positioning, and therefore the whether you can see them or not.

I went through the logs for a site for the period before this happened on one of the sites. I wanted to see if a user had changed a setting inadvertently. But the only interactions were views or edits to courses. No changes were made to any of the administration pages. Also, I'm not aware of a setting that would hide blocks only for administrators.

Nobody has edited the core or theme CSS files for these sites, as I'm the only person (other than server admin) with access to the files.

This issue has occurred before on different sites, but has 'magically' resolved itself a week or so later.

Has anybody else encountered (and hopefully resolved) this, or a similar, issue?

Thanks

Barry

 

 

 
Average of ratings: -
Picture of Barry Richards
Re: Disappearing Moodle 2 blocks for site administrators
 

I have logged this as a bug. You can find the bug report at https://tracker.moodle.org/browse/MDL-37486

For the benefit of the developers fixing this, I have attached some screenshots of an effected site.

 
Average of ratings: -
Picture of Barry Richards
Re: Disappearing Moodle 2 blocks for site administrators
 

This is the site with the bug in action


 
Average of ratings: -
Picture of Barry Richards
Re: Disappearing Moodle 2 blocks for site administrators
 

This is the site as it should be rendered


 
Average of ratings: -
It's only an avatar...
Re: Disappearing Moodle 2 blocks for site administrators
Group DevelopersGroup Documentation writersGroup Particularly helpful MoodlersGroup Testers

Hi Barry,

Can you tell me if the Site News is added by one person or many? Also can you tell me if any of those posts are stripped of Microsoft Word formatting?

Mary

 
Average of ratings: -
Picture of Barry Richards
Re: Disappearing Moodle 2 blocks for site administrators
 

Hi Mary,

To the best of my knowledge (and from looking at the site) only two accounts add site news to the front page, one of which is the site admin account. Several people have access to the site admin account, though I'm certain none of them copy from Word. I don't think the other account user copies HTML from Word either from looking at the code, I will attempt to find out from that user what they do.

Thanks,

Barry

 
Average of ratings: -
Picture of Barry Richards
Re: Disappearing Moodle 2 blocks for site administrators
 

Problem solved, here is the fix:

DO NOT COPY/PASTE CONTENT DIRECT FROM WORD OR OUTLOOK INTO MOODLE!

Copy/paste from Word/Outlook retains HTML formatting, this will break your layout. Instead use the paste text only button, this removes Word/Outlook HTML formatting (see attached image where the button is highlighted).

For a further discussion of problems caused by Word/Outlook HTML formatting see this thread: https://moodle.org/mod/forum/discuss.php?d=143900

Many thanks to Mary Evans for diagnosing this user error issue.


 
Average of ratings:Useful (1)
It's only an avatar...
Re: Disappearing Moodle 2 blocks for site administrators
Group DevelopersGroup Documentation writersGroup Particularly helpful MoodlersGroup Testers

So glad this got sorted out!

Cheers

Cheers all round!

Mary

 
Average of ratings: -
Picture of Siamak Alavi
Re: Disappearing Moodle 2 blocks for site administrators
 

Hi Mary,

I'm having same problem, but I can't find witch user pasted word format.

In dev server, I have deleted all courses and posts but still can not get the admin block, 

How did you fixed this on your noodle?

Thank you

 
Average of ratings: -