Issue Details (XML | Word | Printable)

Key: MDL-6368
Type: Sub-task Sub-task
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Tim Hunt
Reporter: Tim Hunt
Votes: 0
Watchers: 0
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle
MDL-2727

Any qtype CSS has to be copy and pasted into the theme

Created: 26/Aug/06 02:51 PM   Updated: 27/Aug/08 09:49 AM
Return to search
Component/s: Questions
Affects Version/s: 1.7
Fix Version/s: 1.9

Issue Links:
Relates
 

Participants: Tim Hunt
Security Level: None
Resolved date: 12/Apr/07
Affected Branches: MOODLE_17_STABLE
Fixed Branches: MOODLE_19_STABLE


 Description  « Hide
If the question type wants any CSS, at the moment this needs to be copy pasted into the theme CSS files.

 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Tim Hunt made changes - 26/Aug/06 02:52 PM
Field Original Value New Value
Description If the question type wants any CSS, at the moment this needs to be copy pasted into the theme CSS files.
Priority Major [ 3 ] Minor [ 4 ]
Affects Version/s 1.7 [ 10120 ]
Assignee Martin Dougiamas [ dougiamas ] Tim Hunt [ timhunt ]
Component/s Questions [ 10087 ]
tjhunt committed 4 files to 'Moodle CVS' - 12/Apr/07 11:58 PM
MDL-6368 and MDL-6369 - allow question type plugins to easily provide some bits of Javascript and CSS.

If there are any of the files styles.css, styles.php, script.js or script.php in the plugin folder, they will be linked to in the head of the quiz attempt page (only for the question types used on that page).

If you need to do something more complicated in your question type, you can override the get_html_head_contributions method instead.
MODIFY question/type/random/questiontype.php   Rev. 1.9    (+7 -1 lines)
MODIFY mod/quiz/attempt.php   Rev. 1.113    (+6 -5 lines)
MODIFY lib/questionlib.php   Rev. 1.96    (+31 -7 lines)
MODIFY question/type/questiontype.php   Rev. 1.52    (+95 -27 lines)
Tim Hunt added a comment - 12/Apr/07 11:59 PM
To use this, you just need to put a styles.css or styles.php file in the question type folder. If you want to do something more complicated, override the get_html_head_contributions method defined in the base class.

Tim Hunt made changes - 12/Apr/07 11:59 PM
Fix Version/s 1.9 [ 10190 ]
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]
tjhunt committed 1 file to 'Moodle CVS' - 25/Apr/07 01:32 AM
MDL-6368 and MDL-6369 - allow question type plugins to easily provide some bits of Javascript and CSS - I forgot about the review page.
MODIFY mod/quiz/review.php   Rev. 1.54    (+30 -29 lines)
tjhunt committed 1 file to 'Moodle CVS' - 27/Apr/07 07:18 PM
MDL-6368 and MDL-6369 - supplimental - I missed one bit.
MODIFY mod/quiz/attempt.php   Rev. 1.117    (+3 -3 lines)
Tim Hunt made changes - 27/Aug/08 09:49 AM
Link This issue has been marked as being related by MDL-16219 [ MDL-16219 ]
tjhunt committed 2 files to 'Moodle CVS' - 28/Aug/08 10:15 AM
MDL-16219 - mod/quiz/reviewquestion.php does not call questiontype::get_html_head_contributions. This was missed when implementing MDL-6368.
MODIFY mod/quiz/reviewquestion.php   Rev. 1.29    (+3 -2 lines)
MODIFY mod/quiz/attemptlib.php   Rev. 1.15    (+5 -0 lines)
tjhunt committed 1 file to 'Moodle CVS' on branch 'MOODLE_19_STABLE' - 28/Aug/08 10:15 AM
MDL-16219 - mod/quiz/reviewquestion.php does not call questiontype::get_html_head_contributions. This was missed when implementing MDL-6368.
MODIFY mod/quiz/reviewquestion.php   Rev. 1.16.10.6    (+13 -11 lines)