Quiz display left-alignment

Quiz display left-alignment

by Mike Nowinski -
Number of replies: 13

There was a post that explained how to get your Quiz questiions and answers left aligned, but I think it is for pre-V1.5.3.

Can someone pointme to a method to do it for V1.5.3?

Thanks,

Mike

రేటింగుల సగటు: -
In reply to Mike Nowinski

Re: Quiz display left-alignment

by Helen Foster -
Core developers బొమ్మ Documentation writers బొమ్మ Moodle HQ బొమ్మ Particularly helpful Moodlers బొమ్మ Plugin developers బొమ్మ Testers బొమ్మ Translators బొమ్మ
Hi Mike,

Please note that the method explained in MoodleDocs Left-align quiz should work in 1.5.3.
In reply to Helen Foster

Re: Quiz display left-alignment

by Mike Nowinski -

Hi Helen,

Thanks for the reply.

After extracting all the files in the 1.5.3 release and upgrading our server, I selected the "Metal" theme (Unfortunately, the 1.4 Corderouy Blue theme is no longer available).  I cannot find any styles_layout.css file to modify in that theme directory.

Thanks,

Mike

In reply to Mike Nowinski

Re: Quiz display left-alignment

by Helen Foster -
Core developers బొమ్మ Documentation writers బొమ్మ Moodle HQ బొమ్మ Particularly helpful Moodlers బొమ్మ Plugin developers బొమ్మ Testers బొమ్మ Translators బొమ్మ
Hi Mike,

Certain 1.5 themes, such as Metal, build on the standard theme. This means that you can modify styles_layout.css in the standard folder. (Please check MoodleDocs Theme basics for further details.)
In reply to Helen Foster

Re: Quiz display left-alignment

by Mike Nowinski -

Hi Helen,

OK, I found the correct CSS file in the Standard Theme directory and copied the left-align code directly from the  sample to the file under the Modules:Quiz section.  After uploading the file to our server I checked out the results and for some reason the quiz answers are still right-aligned.

Cheers,

Mike in Florida

In reply to Mike Nowinski

Re: Quiz display left-alignment

by Helen Foster -
Core developers బొమ్మ Documentation writers బొమ్మ Moodle HQ బొమ్మ Particularly helpful Moodlers బొమ్మ Plugin developers బొమ్మ Testers బొమ్మ Translators బొమ్మ
Hi Mike,

Please note that a forced refresh (Ctrl+F5) is required in order to see any changes, as browsers usually cache CSS files. Hopefully your quiz will then be displayed left-aligned.
In reply to Helen Foster

Re: Quiz display left-alignment

by Mike Nowinski -

Hi Helen,

I apologize for my lack of knwoledge about all the workings of IE etc., but the Ctrl-F5 did the trick...however,

1.  True/False questions are now left-aligned.

2. MC questions are hit and miss. Some questions have the first answer line right at the end of the question and the succeeding answers inline directly below it.  If the question is more than one line long, the answers are displayed left-aligned correctly.

I changed back to the original CSS file as this was not acceptable.

Perhaps you have seen this condition or have any more insight.

Thanks,

Mike

In reply to Mike Nowinski

Re: Quiz display left-alignment

by Helen Foster -
Core developers బొమ్మ Documentation writers బొమ్మ Moodle HQ బొమ్మ Particularly helpful Moodlers బొమ్మ Plugin developers బొమ్మ Testers బొమ్మ Translators బొమ్మ
Hmm, please could you post a screen shot of a problem multiple choice question.
In reply to Helen Foster

Re: Quiz display left-alignment

by Mike Nowinski -

Hi Helen,

Here's a screenshot of the results after making the changes to the style_layout.css file of the Standard Theme.  #'s 3 and 5 are the culprits in question.  I was looking for the page to have the "Answer" line begin 2 lines below the question, as it is with the right-aligned scheme, but left-aligned.

Note also Answer C for # 5.  Normally in the right-aligned scheme, the answers are not split into two lines, rather the longest answer determines how far to the right the first answer prints.

Thanks for your help.

Attachment Image_060108_190906.jpg
In reply to Mike Nowinski

Re: Quiz display left-alignment

by Helen Foster -
Core developers బొమ్మ Documentation writers బొమ్మ Moodle HQ బొమ్మ Particularly helpful Moodlers బొమ్మ Plugin developers బొమ్మ Testers బొమ్మ Translators బొమ్మ
Hi Mike,

A work around would be to edit the problem questions and press return at the end of the question to insert a couple of line breaks (<br /><br /> in text mode).
Attachment left_align_quiz.png
In reply to Helen Foster

Re: Quiz display left-alignment

by Mike Nowinski -

Hi Helen,

I was afraid of that, as we have many questions that are randomly selected for each test and we constantly update them.  As much as I like Moodle, I didn't think that a fix would have been that involved just to place the text lines to the left instead of the right.  We'll just live with the right-aligned layout until an easier fix is developed. 

Thanks again for all your help, I really appreciate your time and keep up the good work in helping others.

Cheers,

Mike

In reply to Mike Nowinski

Re: Quiz display left-alignment

by Helen Foster -
Core developers బొమ్మ Documentation writers బొమ్మ Moodle HQ బొమ్మ Particularly helpful Moodlers బొమ్మ Plugin developers బొమ్మ Testers బొమ్మ Translators బొమ్మ

Hi Mike,

One last attempt...

Please try adding the following to styles_layout.css:

.mod-quiz .generalboxcontent table {
  margin-top: 5px;
}

(Don't forget the forced refresh wink)

Finally, you may wish to vote for this issue to be properly resolved in the bug tracker - it's bug 4162. Simply create an account with your email address.

In reply to Helen Foster

Re: Quiz display left-alignment

by Mike Nowinski -

Hi Helen,

I added your addtional code to the original fix, but the problem is still there.  It just dropped the first answer line down by about 1/2 line.

Do you know of anyone who has attempted this fix using only the code we have been using and it worked?

Thanks again,

Mike

PS... I will enter a bug report on it as you suggested.