A tumblelog CMS built on AJAX, PHP and MySQL.

xml.php 3.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147
  1. <?php
  2. /*************************************************************************************
  3. * xml.php
  4. * -------
  5. * Author: Nigel McNie (nigel@geshi.org)
  6. * Copyright: (c) 2004 Nigel McNie (http://qbnz.com/highlighter/)
  7. * Release Version: 1.0.7.21
  8. * Date Started: 2004/09/01
  9. *
  10. * XML language file for GeSHi. Based on the idea/file by Christian Weiske
  11. *
  12. * CHANGES
  13. * -------
  14. * 2005/12/28 (1.0.2)
  15. * - Removed escape character for strings
  16. * 2004/11/27 (1.0.1)
  17. * - Added support for multiple object splitters
  18. * 2004/10/27 (1.0.0)
  19. * - First Release
  20. *
  21. * TODO (updated 2004/11/27)
  22. * -------------------------
  23. * * Check regexps work and correctly highlight XML stuff and nothing else
  24. *
  25. *************************************************************************************
  26. *
  27. * This file is part of GeSHi.
  28. *
  29. * GeSHi is free software; you can redistribute it and/or modify
  30. * it under the terms of the GNU General Public License as published by
  31. * the Free Software Foundation; either version 2 of the License, or
  32. * (at your option) any later version.
  33. *
  34. * GeSHi is distributed in the hope that it will be useful,
  35. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  36. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  37. * GNU General Public License for more details.
  38. *
  39. * You should have received a copy of the GNU General Public License
  40. * along with GeSHi; if not, write to the Free Software
  41. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  42. *
  43. ************************************************************************************/
  44. $language_data = array (
  45. 'LANG_NAME' => 'XML',
  46. 'COMMENT_SINGLE' => array(),
  47. 'COMMENT_MULTI' => array('<!--' => '-->'),
  48. 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
  49. 'QUOTEMARKS' => array("'", '"'),
  50. 'ESCAPE_CHAR' => '',
  51. 'KEYWORDS' => array(
  52. ),
  53. 'SYMBOLS' => array(
  54. ),
  55. 'CASE_SENSITIVE' => array(
  56. GESHI_COMMENTS => false,
  57. ),
  58. 'STYLES' => array(
  59. 'KEYWORDS' => array(
  60. ),
  61. 'COMMENTS' => array(
  62. 'MULTI' => 'color: #808080; font-style: italic;'
  63. ),
  64. 'ESCAPE_CHAR' => array(
  65. 0 => 'color: #000099; font-weight: bold;'
  66. ),
  67. 'BRACKETS' => array(
  68. 0 => 'color: #66cc66;'
  69. ),
  70. 'STRINGS' => array(
  71. 0 => 'color: #ff0000;'
  72. ),
  73. 'NUMBERS' => array(
  74. 0 => 'color: #cc66cc;'
  75. ),
  76. 'METHODS' => array(
  77. ),
  78. 'SYMBOLS' => array(
  79. 0 => 'color: #66cc66;'
  80. ),
  81. 'SCRIPT' => array(
  82. 0 => 'color: #00bbdd;',
  83. 1 => 'color: #ddbb00;',
  84. 2 => 'color: #339933;',
  85. 3 => 'color: #009900;'
  86. ),
  87. 'REGEXPS' => array(
  88. 0 => 'color: #000066;',
  89. 1 => 'font-weight: bold; color: black;',
  90. 2 => 'font-weight: bold; color: black;',
  91. )
  92. ),
  93. 'URLS' => array(
  94. ),
  95. 'OOLANG' => false,
  96. 'OBJECT_SPLITTERS' => array(
  97. ),
  98. 'REGEXPS' => array(
  99. 0 => array(
  100. GESHI_SEARCH => '([a-z_\-:]+)(=)',
  101. GESHI_REPLACE => '\\1',
  102. GESHI_MODIFIERS => 'i',
  103. GESHI_BEFORE => '',
  104. GESHI_AFTER => '\\2'
  105. ),
  106. 1 => array(
  107. GESHI_SEARCH => '(&lt;[/?|(\?xml)]?[a-z0-9_\-:]*(\??&gt;)?)',
  108. GESHI_REPLACE => '\\1',
  109. GESHI_MODIFIERS => 'i',
  110. GESHI_BEFORE => '',
  111. GESHI_AFTER => ''
  112. ),
  113. 2 => array(
  114. GESHI_SEARCH => '(([/|\?])?&gt;)',
  115. GESHI_REPLACE => '\\1',
  116. GESHI_MODIFIERS => 'i',
  117. GESHI_BEFORE => '',
  118. GESHI_AFTER => ''
  119. )
  120. ),
  121. 'STRICT_MODE_APPLIES' => GESHI_ALWAYS,
  122. 'SCRIPT_DELIMITERS' => array(
  123. 0 => array(
  124. '<!DOCTYPE' => '>'
  125. ),
  126. 1 => array(
  127. '&' => ';'
  128. ),
  129. 2 => array(
  130. '<![CDATA[' => ']]>'
  131. ),
  132. 3 => array(
  133. '<' => '>'
  134. )
  135. ),
  136. 'HIGHLIGHT_STRICT_BLOCK' => array(
  137. 0 => false,
  138. 1 => false,
  139. 2 => false,
  140. 3 => true
  141. ),
  142. 'TAB_WIDTH' => 4
  143. );
  144. ?>