Crisbal has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/339826 )

Change subject: Generalize quiz selector in JS
......................................................................

Generalize quiz selector in JS

Instead of using the ID "bodyContent" to get the div that is
used to search the quiz instance, it is preferred to use "mw-content-text"
which is skin-indipendent ("bodyContent" is not present in all skins).

Change-Id: I075bfe6801fd2ba9fa5e301818d2b528661fbb3d
---
M modules/ext.quiz.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Quiz 
refs/changes/26/339826/1

diff --git a/modules/ext.quiz.js b/modules/ext.quiz.js
index 54aef43..40165a2 100755
--- a/modules/ext.quiz.js
+++ b/modules/ext.quiz.js
@@ -67,7 +67,7 @@
 
        // Prepare the quiz for "javascriptable" browsers
        function prepareQuiz() {
-               var bodyContentDiv = document.getElementById( 'bodyContent' 
).getElementsByTagName( 'div' );
+               var bodyContentDiv = document.getElementById( 'mw-content-text' 
).getElementsByTagName( 'div' );
                for( var i = 0; i < bodyContentDiv.length; ++i ) {
                        if( bodyContentDiv[i].className === 'quiz' ) {
                                var input = 
bodyContentDiv[i].getElementsByTagName( 'input' );

-- 
To view, visit https://gerrit.wikimedia.org/r/339826
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I075bfe6801fd2ba9fa5e301818d2b528661fbb3d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Quiz
Gerrit-Branch: master
Gerrit-Owner: Crisbal <bld.cris...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to