dokeos
[ class tree: dokeos ] [ index: dokeos ] [ all elements ]

Source for file allowed_tags.inc.php

Documentation is available at allowed_tags.inc.php

  1. <?php
  2. /*
  3. ==============================================================================
  4.     Dokeos - elearning and course management software
  5.  
  6.     Copyright (c) 2004-2005 Dokeos S.A.
  7.     Copyright (c) Bart Mollet, Hogeschool Gent
  8.  
  9.     For a full list of contributors, see "credits.txt".
  10.     The full license can be read in "license.txt".
  11.  
  12.     This program is free software; you can redistribute it and/or
  13.     modify it under the terms of the GNU General Public License
  14.     as published by the Free Software Foundation; either version 2
  15.     of the License, or (at your option) any later version.
  16.  
  17.     See the GNU General Public License for more details.
  18.  
  19.     Contact address: Dokeos, 44 rue des palais, B-1030 Brussels, Belgium
  20.     Mail: info@dokeos.com
  21. ==============================================================================
  22. */
  23. /**
  24.  * This page defines all HTML-tages and their attributes that are allowed in
  25.  * Dokeos. 2 arrays are defined, one contains the allowed HTML for students and
  26.  * the other the allowed HTML for teachers.
  27.  *
  28.  * Modifying this page:
  29.  * - for each allowed tag there should be a line like
  30.  *    $allowed_tags_XXXX   ['tagname'] = array();
  31.  * - for each of the attributes allowed in the tag, there should be a line like
  32.  *    $allowed_tags_XXXX['tagname']['attributename'] = array();
  33.  * - please keep the content of this file alphabetically structured
  34.  */
  35. //============================================================
  36. // ALLOWED HTML FOR STUDENTS
  37. //============================================================
  38. // ADDRESS
  39. $allowed_tags_student['address'=  array();
  40. // APPLET
  41. $allowed_tags_student['applet'=  array();
  42. $allowed_tags_student['applet']['codebase'=  array();
  43. $allowed_tags_student['applet']['code'=  array();
  44. $allowed_tags_student['applet']['name'=  array();
  45. $allowed_tags_student['applet']['alt'=  array();
  46. // AREA
  47. $allowed_tags_student['area'=  array();
  48. $allowed_tags_student['area']['shape'=  array();
  49. $allowed_tags_student['area']['coords'=  array();
  50. $allowed_tags_student['area']['href'=  array();
  51. $allowed_tags_student['area']['alt'=  array();
  52. // A
  53. $allowed_tags_student['a'=  array();
  54. $allowed_tags_student['a']['class'=  array();
  55. $allowed_tags_student['a']['id'=  array();
  56. $allowed_tags_student['a']['href'=  array();
  57. $allowed_tags_student['a']['title'=  array();
  58. $allowed_tags_student['a']['rel'=  array();
  59. $allowed_tags_student['a']['rev'=  array();
  60. $allowed_tags_student['a']['name'=  array();
  61. // ABBR
  62. $allowed_tags_student['abbr'=  array();
  63. $allowed_tags_student['abbr']['title'=  array();
  64. // ACRONYM
  65. $allowed_tags_student['acronym'=  array();
  66. $allowed_tags_student['acronym']['title'=  array();
  67. // B
  68. $allowed_tags_student['b'=  array();
  69. $allowed_tags_student['b']['class'=  array();
  70. $allowed_tags_student['b']['id'=  array();
  71. // BASE
  72. $allowed_tags_student['base'=  array();
  73. $allowed_tags_student['base']['href'=  array();
  74. // BASEFONT
  75. $allowed_tags_student['basefont'=  array();
  76. $allowed_tags_student['basefont']['size'=  array();
  77. // BDO
  78. $allowed_tags_student['bdo'=  array();
  79. $allowed_tags_student['bdo']['dir'=  array();
  80. // BIG
  81. $allowed_tags_student['big'=  array();
  82. // BLOCKQUOTE
  83. $allowed_tags_student['blockquote'=  array();
  84. $allowed_tags_student['blockquote']['cite'=  array();
  85. // BODY
  86. $allowed_tags_student_full_page['body'=  array();
  87. $allowed_tags_student_full_page['body']['alink'=  array();
  88. $allowed_tags_student_full_page['body']['background'=  array();
  89. $allowed_tags_student_full_page['body']['bgcolor'=  array();
  90. $allowed_tags_student_full_page['body']['link'=  array();
  91. $allowed_tags_student_full_page['body']['text'=  array();
  92. $allowed_tags_student_full_page['body']['vlink'=  array();
  93. // BR
  94. $allowed_tags_student['br'=  array();
  95. // BUTTON
  96. $allowed_tags_student['button'=  array();
  97. $allowed_tags_student['button']['disabled'=  array();
  98. $allowed_tags_student['button']['name'=  array();
  99. $allowed_tags_student['button']['type'=  array();
  100. $allowed_tags_student['button']['value'=  array();
  101. // CAPTION
  102. $allowed_tags_student['caption'=  array();
  103. $allowed_tags_student['caption']['align'=  array();
  104. // CODE
  105. $allowed_tags_student['code'=  array();
  106. // COL
  107. $allowed_tags_student['col'=  array();
  108. $allowed_tags_student['col']['align'=  array();
  109. $allowed_tags_student['col']['char'=  array();
  110. $allowed_tags_student['col']['charoff'=  array();
  111. $allowed_tags_student['col']['valign'=  array();
  112. $allowed_tags_student['col']['width'=  array();
  113. // DEL
  114. $allowed_tags_student['del'=  array();
  115. $allowed_tags_student['del']['datetime'=  array();
  116. // DD
  117. $allowed_tags_student['dd'=  array();
  118. // DIV
  119. $allowed_tags_student['div'=  array();
  120. $allowed_tags_student['div']['align'=  array();
  121. $allowed_tags_student['div']['class'=  array();
  122. $allowed_tags_student['div']['id'=  array();
  123. #$allowed_tags_student['div']['style'] =  array(); //filtered out for security (see kses security report)
  124. // DL
  125. $allowed_tags_student['dl'=  array();
  126. // DT
  127. $allowed_tags_student['dt'=  array();
  128. // EM
  129. $allowed_tags_student['em'=  array();
  130. // EMBED
  131. $allowed_tags_student['embed'=  array();
  132. $allowed_tags_student['embed']['height'=  array();
  133. $allowed_tags_student['embed']['type'=  array();
  134. $allowed_tags_student['embed']['quality'=  array();
  135. $allowed_tags_student['embed']['src'=  array();
  136. $allowed_tags_student['embed']['width'=  array();
  137.  
  138. // FIELDSET
  139. $allowed_tags_student['fieldset'=  array();
  140. // FONT
  141. $allowed_tags_student['font'=  array();
  142. $allowed_tags_student['font']['color'=  array();
  143. $allowed_tags_student['font']['face'=  array();
  144. $allowed_tags_student['font']['size'=  array();
  145. //$allowed_tags_student['font']['style'] =  array(); //filtered out for security (see kses security report)
  146. // FORM
  147. $allowed_tags_student['form'=  array();
  148. $allowed_tags_student['form']['action'=  array();
  149. $allowed_tags_student['form']['accept'=  array();
  150. $allowed_tags_student['form']['accept-charset'=  array();
  151. $allowed_tags_student['form']['enctype'=  array();
  152. $allowed_tags_student['form']['method'=  array();
  153. $allowed_tags_student['form']['name'=  array();
  154. $allowed_tags_student['form']['target'=  array();
  155. // FRAME
  156. $allowed_tags_student_full_page['frame'=  array();
  157. $allowed_tags_student_full_page['frame']['frameborder'=  array();
  158. $allowed_tags_student_full_page['frame']['longsesc'=  array();
  159. $allowed_tags_student_full_page['frame']['marginheight'=  array();
  160. $allowed_tags_student_full_page['frame']['marginwidth'=  array();
  161. $allowed_tags_student_full_page['frame']['name'=  array();
  162. $allowed_tags_student_full_page['frame']['noresize'=  array();
  163. $allowed_tags_student_full_page['frame']['scrolling'=  array();
  164. $allowed_tags_student_full_page['frame']['src'=  array();
  165. // FRAMESET
  166. $allowed_tags_student_full_page['frameset'=  array();
  167. $allowed_tags_student_full_page['frameset']['cols'=  array();
  168. $allowed_tags_student_full_page['frameset']['rows'=  array();
  169. // HEAD
  170. $allowed_tags_student_full_page['head'=  array();
  171. $allowed_tags_student_full_page['head']['profile'=  array();
  172. // H1
  173. $allowed_tags_student['h1'=  array();
  174. $allowed_tags_student['h1']['align'=  array();
  175. $allowed_tags_student['h1']['class'=  array();
  176. $allowed_tags_student['h1']['id'=  array();
  177. // H2
  178. $allowed_tags_student['h2'=  array();
  179. $allowed_tags_student['h2']['align'=  array();
  180. $allowed_tags_student['h2']['class'=  array();
  181. $allowed_tags_student['h2']['id'=  array();
  182. // H3
  183. $allowed_tags_student['h3'=  array();
  184. $allowed_tags_student['h3']['align'=  array();
  185. $allowed_tags_student['h3']['class'=  array();
  186. $allowed_tags_student['h3']['id'=  array();
  187. // H4
  188. $allowed_tags_student['h4'=  array();
  189. $allowed_tags_student['h4']['align'=  array();
  190. $allowed_tags_student['h4']['class'=  array();
  191. $allowed_tags_student['h4']['id'=  array();
  192. // H5
  193. $allowed_tags_student['h5'=  array();
  194. $allowed_tags_student['h5']['align'=  array();
  195. $allowed_tags_student['h5']['class'=  array();
  196. $allowed_tags_student['h5']['id'=  array();
  197. // H6
  198. $allowed_tags_student['h6'=  array();
  199. $allowed_tags_student['h6']['align'=  array();
  200. $allowed_tags_student['h6']['class'=  array();
  201. $allowed_tags_student['h6']['id'=  array();
  202. // HR
  203. $allowed_tags_student['hr'=  array();
  204. $allowed_tags_student['hr']['align'=  array();
  205. $allowed_tags_student['hr']['noshade'=  array();
  206. $allowed_tags_student['hr']['size'=  array();
  207. $allowed_tags_student['hr']['width'=  array();
  208. $allowed_tags_student['hr']['class'=  array();
  209. $allowed_tags_student['hr']['id'=  array();
  210. // HTML
  211. $allowed_tags_student_full_page['html'=  array();
  212. $allowed_tags_student_full_page['html']['xmlns'=  array();
  213. // I
  214. $allowed_tags_student['i'=  array();
  215. // IFRAME
  216. $allowed_tags_student['iframe'=  array();
  217. $allowed_tags_student['iframe']['align'=  array();
  218. $allowed_tags_student['iframe']['frameborder'=  array();
  219. $allowed_tags_student['iframe']['height'=  array();
  220. $allowed_tags_student['iframe']['londesc'=  array();
  221. $allowed_tags_student['iframe']['marginheight'=  array();
  222. $allowed_tags_student['iframe']['marginwidth'=  array();
  223. $allowed_tags_student['iframe']['name'=  array();
  224. $allowed_tags_student['iframe']['scrolling'=  array();
  225. $allowed_tags_student['iframe']['src'=  array();
  226. $allowed_tags_student['iframe']['width'=  array();
  227. // IMG
  228. $allowed_tags_student['img'=  array();
  229. $allowed_tags_student['img']['alt'=  array();
  230. $allowed_tags_student['img']['align'=  array();
  231. $allowed_tags_student['img']['border'=  array();
  232. $allowed_tags_student['img']['height'=  array();
  233. $allowed_tags_student['img']['hspace'=  array();
  234. $allowed_tags_student['img']['ismap'=  array();
  235. $allowed_tags_student['img']['longdesc'=  array();
  236. $allowed_tags_student['img']['src'=  array();
  237. $allowed_tags_student['img']['usemap'=  array();
  238. $allowed_tags_student['img']['vspace'=  array();
  239. $allowed_tags_student['img']['width'=  array();
  240. // INPUT
  241. $allowed_tags_student['input'=  array();
  242. $allowed_tags_student['input']['accept'=  array();
  243. $allowed_tags_student['input']['align'=  array();
  244. $allowed_tags_student['input']['alt'=  array();
  245. $allowed_tags_student['input']['checked'=  array();
  246. $allowed_tags_student['input']['disabled'=  array();
  247. $allowed_tags_student['input']['maxlength'=  array();
  248. $allowed_tags_student['input']['name'=  array();
  249. $allowed_tags_student['input']['readonly'=  array();
  250. $allowed_tags_student['input']['size'=  array();
  251. $allowed_tags_student['input']['src'=  array();
  252. $allowed_tags_student['input']['type'=  array();
  253. $allowed_tags_student['input']['value'=  array();
  254. // INS
  255. $allowed_tags_student['ins'=  array();
  256. $allowed_tags_student['ins']['datetime'=  array();
  257. $allowed_tags_student['ins']['cite'=  array();
  258. // KBD
  259. $allowed_tags_student['kbd'=  array();
  260. // LABEL
  261. $allowed_tags_student['label'=  array();
  262. $allowed_tags_student['label']['for'=  array();
  263. // LEGEND
  264. $allowed_tags_student['legend'=  array();
  265. $allowed_tags_student['legend']['align'=  array();
  266. // LI
  267. $allowed_tags_student['li'=  array();
  268. // LINK
  269. $allowed_tags_student_full_page['link'=  array();
  270. $allowed_tags_student_full_page['link']['charset'=  array();
  271. $allowed_tags_student_full_page['link']['href'=  array();
  272. $allowed_tags_student_full_page['link']['hreflang'=  array();
  273. $allowed_tags_student_full_page['link']['media'=  array();
  274. $allowed_tags_student_full_page['link']['rel'=  array();
  275. $allowed_tags_student_full_page['link']['rev'=  array();
  276. $allowed_tags_student_full_page['link']['target'=  array();
  277. $allowed_tags_student_full_page['link']['type'=  array();
  278. // MAP
  279. $allowed_tags_student['map'=  array();
  280. $allowed_tags_student['map']['id'=  array();
  281. $allowed_tags_student['map']['name'=  array();
  282. // MENU
  283. $allowed_tags_student['menu'=  array();
  284. // META
  285. $allowed_tags_student_full_page['meta'=  array();
  286. $allowed_tags_student_full_page['meta']['content'=  array();
  287. $allowed_tags_student_full_page['meta']['http-equiv'=  array();
  288. $allowed_tags_student_full_page['meta']['name'=  array();
  289. $allowed_tags_student_full_page['meta']['scheme'=  array();
  290. // NOFRAMES
  291. $allowed_tags_student_full_page['noframes'=  array();
  292. // OBJECT
  293. $allowed_tags_student['object'=  array();
  294. $allowed_tags_student['object']['align'=  array();
  295. $allowed_tags_student['object']['archive'=  array();
  296. $allowed_tags_student['object']['border'=  array();
  297. $allowed_tags_student['object']['classid'=  array();
  298. $allowed_tags_student['object']['codebase'=  array();
  299. $allowed_tags_student['object']['codetype'=  array();
  300. $allowed_tags_student['object']['data'=  array();
  301. $allowed_tags_student['object']['declare'=  array();
  302. $allowed_tags_student['object']['height'=  array();
  303. $allowed_tags_student['object']['hspace'=  array();
  304. $allowed_tags_student['object']['name'=  array();
  305. $allowed_tags_student['object']['standby'=  array();
  306. $allowed_tags_student['object']['type'=  array();
  307. $allowed_tags_student['object']['usemap'=  array();
  308. $allowed_tags_student['object']['vspace'=  array();
  309. $allowed_tags_student['object']['width'=  array();
  310. // OL
  311. $allowed_tags_student['ol'=  array();
  312. $allowed_tags_student['ol']['compact'=  array();
  313. $allowed_tags_student['ol']['start'=  array();
  314. $allowed_tags_student['ol']['type'=  array();
  315. // OPTGROUP
  316. $allowed_tags_student['optgroup'=  array();
  317. $allowed_tags_student['optgroup']['label'=  array();
  318. $allowed_tags_student['optgroup']['disabled'=  array();
  319. // OPTION
  320. $allowed_tags_student['option'=  array();
  321. $allowed_tags_student['option']['disabled'=  array();
  322. $allowed_tags_student['option']['label'=  array();
  323. $allowed_tags_student['option']['selected'=  array();
  324. $allowed_tags_student['option']['value'=  array();
  325. // P
  326. $allowed_tags_student['p'=  array();
  327. $allowed_tags_student['p']['align'=  array();
  328. // PARAM
  329. $allowed_tags_student['param'=  array();
  330. $allowed_tags_student['param']['name'=  array();
  331. $allowed_tags_student['param']['type'=  array();
  332. $allowed_tags_student['param']['value'=  array();
  333. $allowed_tags_student['param']['valuetype'=  array();
  334. // PRE
  335. $allowed_tags_student['pre'=  array();
  336. $allowed_tags_student['pre']['width'=  array();
  337. // Q
  338. $allowed_tags_student['q'=  array();
  339. $allowed_tags_student['q']['cite'=  array();
  340. // S
  341. $allowed_tags_student['s'=  array();
  342. // SPAN
  343. $allowed_tags_student['span'=  array();
  344. #$allowed_tags_student['span']['style'] =  array(); //filtered out for security (see kses security report)
  345. // STRIKE
  346. $allowed_tags_student['strike'=  array();
  347. // STRONG
  348. $allowed_tags_student['strong'=  array();
  349. // STYLE  //filtered out for security (see kses security report)
  350. #$allowed_tags_student['style'] =  array();
  351. #$allowed_tags_student['style']['type'] =  array();
  352. #$allowed_tags_student['style']['media'] =  array();
  353.  
  354. #$allowed_tags_student_full_page['style'] =  array();
  355. #$allowed_tags_student_full_page['style']['type'] =  array();
  356. #$allowed_tags_student_full_page['style']['media'] =  array();
  357. // SUB
  358. $allowed_tags_student['sub'=  array();
  359. // SUP
  360. $allowed_tags_student['sup'=  array();
  361. // TABLE
  362. $allowed_tags_student['table'=  array();
  363. $allowed_tags_student['table']['align'=  array();
  364. $allowed_tags_student['table']['bgcolor'=  array();
  365. $allowed_tags_student['table']['border'=  array();
  366. $allowed_tags_student['table']['cellpadding'=  array();
  367. $allowed_tags_student['table']['cellspacing'=  array();
  368. $allowed_tags_student['table']['frame'=  array();
  369. $allowed_tags_student['table']['rules'=  array();
  370. $allowed_tags_student['table']['summary'=  array();
  371. $allowed_tags_student['table']['width'=  array();
  372. // TBODY
  373. $allowed_tags_student['tbody'=  array();
  374. $allowed_tags_student['tbody']['align'=  array();
  375. $allowed_tags_student['tbody']['char'=  array();
  376. $allowed_tags_student['tbody']['charoff'=  array();
  377. $allowed_tags_student['tbody']['valign'=  array();
  378. // TD
  379. $allowed_tags_student['td'=  array();
  380. $allowed_tags_student['td']['abbr'=  array();
  381. $allowed_tags_student['td']['align'=  array();
  382. $allowed_tags_student['td']['axis'=  array();
  383. $allowed_tags_student['td']['bgcolor'=  array();
  384. $allowed_tags_student['td']['char'=  array();
  385. $allowed_tags_student['td']['charoff'=  array();
  386. $allowed_tags_student['td']['colspan'=  array();
  387. $allowed_tags_student['td']['headers'=  array();
  388. $allowed_tags_student['td']['height'=  array();
  389. $allowed_tags_student['td']['nowrap'=  array();
  390. $allowed_tags_student['td']['rowspan'=  array();
  391. $allowed_tags_student['td']['scope'=  array();
  392. $allowed_tags_student['td']['valign'=  array();
  393. $allowed_tags_student['td']['width'=  array();
  394. // TEXTAREA
  395. $allowed_tags_student['textarea'=  array();
  396. $allowed_tags_student['textarea']['cols'=  array();
  397. $allowed_tags_student['textarea']['rows'=  array();
  398. $allowed_tags_student['textarea']['disabled'=  array();
  399. $allowed_tags_student['textarea']['name'=  array();
  400. $allowed_tags_student['textarea']['readonly'=  array();
  401. // TFOOT
  402. $allowed_tags_student['tfoot'=  array();
  403. $allowed_tags_student['tfoot']['align'=  array();
  404. $allowed_tags_student['tfoot']['char'=  array();
  405. $allowed_tags_student['tfoot']['charoff'=  array();
  406. $allowed_tags_student['tfoot']['valign'=  array();
  407. // TH
  408. $allowed_tags_student['th'=  array();
  409. $allowed_tags_student['th']['abbr'=  array();
  410. $allowed_tags_student['th']['align'=  array();
  411. $allowed_tags_student['th']['axis'=  array();
  412. $allowed_tags_student['th']['bgcolor'=  array();
  413. $allowed_tags_student['th']['char'=  array();
  414. $allowed_tags_student['th']['charoff'=  array();
  415. $allowed_tags_student['th']['colspan'=  array();
  416. $allowed_tags_student['th']['headers'=  array();
  417. $allowed_tags_student['th']['height'=  array();
  418. $allowed_tags_student['th']['nowrap'=  array();
  419. $allowed_tags_student['th']['rowspan'=  array();
  420. $allowed_tags_student['th']['scope'=  array();
  421. $allowed_tags_student['th']['valign'=  array();
  422. $allowed_tags_student['th']['width'=  array();
  423. // THEAD
  424. $allowed_tags_student['thead'=  array();
  425. $allowed_tags_student['thead']['align'=  array();
  426. $allowed_tags_student['thead']['char'=  array();
  427. $allowed_tags_student['thead']['charoff'=  array();
  428. $allowed_tags_student['thead']['valign'=  array();
  429. // TITLE
  430. $allowed_tags_student['title'=  array();
  431. // TR
  432. $allowed_tags_student['tr'=  array();
  433. $allowed_tags_student['tr']['align'=  array();
  434. $allowed_tags_student['tr']['bgcolor'=  array();
  435. $allowed_tags_student['tr']['char'=  array();
  436. $allowed_tags_student['tr']['charoff'=  array();
  437. $allowed_tags_student['tr']['valign'=  array();
  438. // TT
  439. $allowed_tags_student['tt'=  array();
  440. // U
  441. $allowed_tags_student['u'=  array();
  442. // UL
  443. $allowed_tags_student['ul'=  array();
  444. // VAR
  445. $allowed_tags_student['var'=  array();
  446. //============================================================
  447. // ALLOWED HTML FOR TEACHERS
  448. //============================================================
  449. // Allow all HTML allowed for students
  450. $allowed_tags_teacher $allowed_tags_student;
  451. // NOSCRIPT
  452. $allowed_tags_teacher['noscript'=  array();
  453. // SCRIPT
  454. $allowed_tags_teacher['script'array();
  455. $allowed_tags_teacher['script']['type'array();
  456.  
  457. $allowed_tags_teacher['html'=  array();
  458. $allowed_tags_teacher['html']['xmlns'=  array();
  459.  
  460. $allowed_tags_teacher['head'=  array();
  461. $allowed_tags_teacher['head']['profile'=  array();
  462.  
  463. // BODY
  464. $allowed_tags_teacher['body'=  array();
  465. $allowed_tags_teacher['body']['alink'=  array();
  466. $allowed_tags_teacher['body']['background'=  array();
  467. $allowed_tags_teacher['body']['bgcolor'=  array();
  468. $allowed_tags_teacher['body']['link'=  array();
  469. $allowed_tags_teacher['body']['text'=  array();
  470. $allowed_tags_teacher['body']['vlink'=  array();
  471.  
  472.  
  473. $allowed_tags_teacher_full_page $allowed_tags_student_full_page;
  474. ?>

Documentation generated on Thu, 12 Jun 2008 12:57:35 -0500 by phpDocumentor 1.4.1