Index: trunk/extensions/SimpleSurvey/SimpleSurvey.php |
— | — | @@ -22,9 +22,7 @@ |
23 | 23 | 'SpecialSimpleSurvey' => $dir . 'SpecialSimpleSurvey.php', |
24 | 24 | ) |
25 | 25 | ); |
26 | | -unset( $prefswitchdir ); |
27 | 26 | |
28 | | - |
29 | 27 | // add special pages |
30 | 28 | $wgSpecialPages['SimpleSurvey'] = 'SpecialSimpleSurvey'; |
31 | 29 | $wgSpecialPageGroups['SimpleSurvey'] = 'wiki'; |
— | — | @@ -46,12 +44,10 @@ |
47 | 45 | |
48 | 46 | // add surveys |
49 | 47 | require_once( $dir . "Surveys.php" ); |
50 | | -unset( $dir ); |
51 | 48 | |
52 | 49 | // Always include the browser stuff... |
53 | | -foreach ( $wgPrefSwitchSurveys as $survey ) { |
| 50 | +foreach ( $wgPrefSwitchSurveys as &$survey ) { |
54 | 51 | $survey['questions']['browser'] = array( |
55 | | - 'visibility' => "hidden", |
56 | 52 | 'question' => 'prefswitch-survey-question-browser', |
57 | 53 | 'type' => 'select', |
58 | 54 | 'answers' => array( |
— | — | @@ -59,14 +55,21 @@ |
60 | 56 | 'ie6' => 'prefswitch-survey-answer-browser-ie6', |
61 | 57 | 'ie7' => 'prefswitch-survey-answer-browser-ie7', |
62 | 58 | 'ie8' => 'prefswitch-survey-answer-browser-ie8', |
| 59 | + 'ie9' => 'prefswitch-survey-answer-browser-ie9', |
| 60 | + 'ffb' => 'prefswitch-survey-answer-browser-ffb', |
63 | 61 | 'ff1' => 'prefswitch-survey-answer-browser-ff1', |
64 | 62 | 'ff2' => 'prefswitch-survey-answer-browser-ff2', |
65 | 63 | 'ff3' => 'prefswitch-survey-answer-browser-ff3', |
66 | 64 | 'cb' => 'prefswitch-survey-answer-browser-cb', |
| 65 | + 'cd' => 'prefswitch-survey-answer-browser-cd', |
67 | 66 | 'c1' => 'prefswitch-survey-answer-browser-c1', |
68 | 67 | 'c2' => 'prefswitch-survey-answer-browser-c2', |
| 68 | + 'c3' => 'prefswitch-survey-answer-browser-c3', |
| 69 | + 'c4' => 'prefswitch-survey-answer-browser-c4', |
| 70 | + 'c5' => 'prefswitch-survey-answer-browser-c5', |
69 | 71 | 's3' => 'prefswitch-survey-answer-browser-s3', |
70 | 72 | 's4' => 'prefswitch-survey-answer-browser-s4', |
| 73 | + 's5' => 'prefswitch-survey-answer-browser-s5', |
71 | 74 | 'o9' => 'prefswitch-survey-answer-browser-o9', |
72 | 75 | 'o9.5' => 'prefswitch-survey-answer-browser-o9.5', |
73 | 76 | 'o10' => 'prefswitch-survey-answer-browser-o10', |
— | — | @@ -75,20 +78,19 @@ |
76 | 79 | ); |
77 | 80 | $survey['questions']['os'] = array( |
78 | 81 | 'question' => 'prefswitch-survey-question-os', |
79 | | - 'visibility' => "hidden", |
80 | 82 | 'type' => 'select', |
81 | | - 'answers' => array( |
| 83 | + 'answers' => array( |
82 | 84 | 'windows' => 'prefswitch-survey-answer-os-windows', |
83 | 85 | 'windowsmobile' => 'prefswitch-survey-answer-os-windowsmobile', |
84 | 86 | 'macos' => 'prefswitch-survey-answer-os-macos', |
85 | 87 | 'iphoneos' => 'prefswitch-survey-answer-os-iphoneos', |
| 88 | + 'ios' => 'prefswitch-survey-answer-os-ios', |
86 | 89 | 'linux' => 'prefswitch-survey-answer-os-linux', |
87 | 90 | ), |
88 | 91 | 'other' => 'prefswitch-survey-answer-os-other', |
89 | 92 | ); |
90 | 93 | $survey['questions']['res'] = array( |
91 | 94 | 'question' => 'prefswitch-survey-question-res', |
92 | | - 'visibility' => "hidden", |
93 | 95 | 'type' => 'dimensions', |
94 | 96 | ); |
95 | 97 | } |
Index: trunk/extensions/SimpleSurvey/SpecialSimpleSurvey.php |
— | — | @@ -29,8 +29,9 @@ |
30 | 30 | if ( $this->tokenToCheck != "" && |
31 | 31 | ( $wgRequest->getVal( 'token' ) == $this->tokenToCheck ) ) { |
32 | 32 | return true; |
| 33 | + } else { |
| 34 | + return false; |
33 | 35 | } |
34 | | - else return false; |
35 | 36 | } |
36 | 37 | |
37 | 38 | public function setToken() { |