Index: trunk/extensions/EtherpadLite/EtherpadLite.php |
— | — | @@ -70,43 +70,43 @@ |
71 | 71 | ); |
72 | 72 | |
73 | 73 | $dir = dirname( __FILE__ ) . '/'; |
74 | | - |
75 | 74 | $wgExtensionMessagesFiles['EtherpadLite'] = $dir . 'EtherpadLite.i18n.php'; |
76 | 75 | $wgHooks['ParserFirstCallInit'][] = 'EtherpadLite::EtherpadLiteParserInit'; |
77 | 76 | |
78 | | -class EtherpadLite { |
| 77 | +# Define a default Etherpad Lite server Url and base path |
| 78 | +# this server is used unless a distinct server is defined by id="..." |
| 79 | +$wgEtherpadLiteDefaultPadUrl = "http://beta.etherpad.org/p/"; |
79 | 80 | |
80 | | - # Define a default Etherpad Lite server Url and base path |
81 | | - # this server is used unless a distinct server is defined by id="..." |
82 | | - public $wgEtherpadLiteDefaultPadUrl = "http://beta.etherpad.org/p/"; |
| 81 | +$wgEtherpadLiteDefaultWidth = "300px"; |
| 82 | +$wgEtherpadLiteDefaultHeight = "200px"; |
| 83 | +$wgEtherpadLiteMonospacedFont = false; |
| 84 | +$wgEtherpadLiteShowControls = true; |
| 85 | +$wgEtherpadLiteShowLineNumbers = true; |
| 86 | +$wgEtherpadLiteShowChat = true; |
| 87 | +$wgEtherpadLiteShowAuthorColors = true; |
83 | 88 | |
84 | | - public $wgEtherpadLiteDefaultWidth = "300px"; |
85 | | - public $wgEtherpadLiteDefaultHeight = "200px"; |
86 | | - public $wgEtherpadLiteMonospacedFont = false; |
87 | | - public $wgEtherpadLiteShowControls = true; |
88 | | - public $wgEtherpadLiteShowLineNumbers = true; |
89 | | - public $wgEtherpadLiteShowChat = true; |
90 | | - public $wgEtherpadLiteShowAuthorColors = true; |
| 89 | +# Whitelist of allowed Etherpad Lite server Urls |
| 90 | +# |
| 91 | +# If there are items in the array, and the user supplied URL is not in the array, |
| 92 | +# the url will not be allowed (proposed in bug 27768 for Extension:RSS) |
| 93 | +# Attention: |
| 94 | +# Urls are case-sensitively tested against values in the array. |
| 95 | +# They must exactly match including any trailing "/" character. |
| 96 | +# |
| 97 | +# Warning: Allowing all urls (not setting a whitelist) |
| 98 | +# may be a security concern. |
| 99 | +# |
| 100 | +# an empty or non-existent array means: no whitelist defined |
| 101 | +# this is the default: an empty whitelist. No servers are allowed by default. |
91 | 102 | |
92 | | - # Whitelist of allowed Etherpad Lite server Urls |
93 | | - # |
94 | | - # If there are items in the array, and the user supplied URL is not in the array, |
95 | | - # the url will not be allowed (proposed in bug 27768 for Extension:RSS) |
96 | | - # Attention: |
97 | | - # Urls are case-sensitively tested against values in the array. |
98 | | - # They must exactly match including any trailing "/" character. |
99 | | - # |
100 | | - # Warning: Allowing all urls (not setting a whitelist) |
101 | | - # may be a security concern. |
102 | | - # |
103 | | - # an empty or non-existent array means: no whitelist defined |
104 | | - # this is the default: an empty whitelist. No servers are allowed by default. |
| 103 | +$wgEtherpadLiteUrlWhitelist = array(); |
105 | 104 | |
106 | | - public $wgEtherpadLiteUrlWhitelist = array(); |
107 | | - |
108 | | - # include "*" if you expressly want to allow all urls (you should not do this) |
109 | | - # $wgEtherpadLiteUrlWhitelist = array( "*" ); |
| 105 | +# include "*" if you expressly want to allow all urls (you should not do this) |
| 106 | +# $wgEtherpadLiteUrlWhitelist = array( "*" ); |
110 | 107 | |
| 108 | + |
| 109 | +class EtherpadLite { |
| 110 | + |
111 | 111 | /** |
112 | 112 | * Tell the parser how to handle <eplite> elements |
113 | 113 | * https://www.mediawiki.org/wiki/Manual:Tag_extensions |