index.php 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270
  1. <?php
  2. require_once "../public/load_lang.php";
  3. require_once "../path.php";
  4. require_once "../pcdl/html_head.php";
  5. ?>
  6. <body style="margin: 0;padding: 0;" class="reader_body" >
  7. <script src="../channal/channal.js"></script>
  8. <script src="./reader.js"></script>
  9. <script src="../widget/click_dropdown.js"></script>
  10. <link type="text/css" rel="stylesheet" href="../widget/click_dropdown.css"/>
  11. <link type="text/css" rel="stylesheet" href="style.css" />
  12. <link type="text/css" rel="stylesheet" href="mobile.css" media="screen and (max-width:800px)" />
  13. <link type="text/css" rel="stylesheet" href="print.css" media="print" />
  14. <script>
  15. <?php
  16. $_view = "";
  17. $_display = "";
  18. $_channal = "";
  19. $_collect = "";
  20. if(isset($_GET["view"])){
  21. echo "_reader_view='".$_GET["view"]."';";
  22. }
  23. if(isset($_GET["book"])){
  24. echo "_reader_book='".$_GET["book"]."';";
  25. }
  26. if(isset($_GET["para"])){
  27. echo "_reader_para='".$_GET["para"]."';";
  28. }
  29. if(isset($_GET["begin"])){
  30. echo "_reader_begin='".$_GET["begin"]."';";
  31. }
  32. if(isset($_GET["end"])){
  33. echo "_reader_end='".$_GET["end"]."';";
  34. }
  35. if(isset($_GET["display"])){
  36. echo "_display='".$_GET["display"]."';";
  37. }
  38. if(isset($_GET["channal"])){
  39. echo "_channal='".$_GET["channal"]."';";
  40. }
  41. if(isset($_GET["lang"])){
  42. echo "_lang='".$_GET["lang"]."';";
  43. }
  44. if(isset($_GET["author"])){
  45. echo "_author='".$_GET["author"]."';";
  46. }
  47. ?>
  48. </script>
  49. <?php
  50. require_once("../pcdl/head_bar.php");
  51. ?>
  52. <div id="head_bar" >
  53. <div id="pali_pedia" style="display:flex;">
  54. <span><?php echo $_local->gui->anthology; ?></span>
  55. </div>
  56. <div>
  57. <span>
  58. <input type="checkbox" onchange="setVisibility('palitext',this)" checked><?php echo $_local->gui->script; ?>
  59. <?php
  60. //echo "<button class='icon_btn' title='{$_local->gui->add}{$_local->gui->subfield}'>";
  61. //echo "<a href='../article/frame.php?id=".$_GET["id"];
  62. //echo "'>{$_local->gui->add}{$_local->gui->subfield}</a></button>";
  63. if(isset($_GET["display"]) && $_GET["display"]=="para"){
  64. echo "<button class='icon_btn active' title='{$_local->gui->show} {$_local->gui->each_paragraph}'>";
  65. echo $_local->gui->each_paragraph;
  66. echo "</button>";
  67. }
  68. else{
  69. echo "<button class='icon_btn'>";
  70. echo "<a href='../reader/?view=".$_GET["view"];
  71. if(isset($_GET["book"])){
  72. echo "&book=".$_GET["book"];
  73. }
  74. if(isset($_GET["para"])){
  75. echo "&para=".$_GET["para"];
  76. }
  77. if(isset($_GET["begin"])){
  78. echo "&begin=".$_GET["begin"];
  79. }
  80. if(isset($_GET["end"])){
  81. echo "&end=".$_GET["end"];
  82. }
  83. if(isset($_GET["channal"])){
  84. echo "&channal=".$_GET["channal"];
  85. }
  86. if(isset($_GET["lang"])){
  87. echo "&lang=".$_GET["lang"];
  88. }
  89. echo "&display=para' title='{$_local->gui->show} {$_local->gui->each_paragraph}'>";
  90. echo $_local->gui->each_paragraph;
  91. echo "</a>";
  92. echo "</button>";
  93. }
  94. if(isset($_GET["display"]) && $_GET["display"]=="sent"){
  95. echo "<button class='icon_btn active' title='{$_local->gui->show} {$_local->gui->each_sentence}'>";
  96. echo $_local->gui->each_sentence;
  97. echo "</button>";
  98. }
  99. else{
  100. echo "<button class='icon_btn'>";
  101. echo "<a href='../reader/?view=".$_GET["view"];
  102. if(isset($_GET["book"])){
  103. echo "&book=".$_GET["book"];
  104. }
  105. if(isset($_GET["para"])){
  106. echo "&para=".$_GET["para"];
  107. }
  108. if(isset($_GET["begin"])){
  109. echo "&begin=".$_GET["begin"];
  110. }
  111. if(isset($_GET["end"])){
  112. echo "&end=".$_GET["end"];
  113. }
  114. if(isset($_GET["channal"])){
  115. echo "&channal=".$_GET["channal"];
  116. }
  117. if(isset($_GET["lang"])){
  118. echo "&lang=".$_GET["lang"];
  119. }
  120. echo "&display=sent";
  121. echo "' title='{$_local->gui->show} {$_local->gui->each_sentence}'>{$_local->gui->each_sentence}</a></button>";
  122. }
  123. ?>
  124. <button class='icon_btn'><a><?php echo $_local->gui->help; ?></a></button>
  125. <button id="btn_show_dict" class='icon_btn' onclick="show_dict(this)"><a ><?php echo $_local->gui->dict; ?></a></button>
  126. </span>
  127. </div>
  128. </div>
  129. <div id="main_view" class="main_view">
  130. <div id="article_head" style="border-bottom: 1px solid gray;">
  131. <div id="article_title" class="term_word_head_pali"><?php echo $_local->gui->title; ?></div>
  132. <div id='path_div' style="display:flex;justify-content: space-between;">
  133. <div id="article_path">
  134. <span id="para_path"></span>
  135. <span class="case_dropdown" id="para_path_next_level">
  136. ……
  137. <div id="toc_next_menu" class="case_dropdown-content">
  138. </div>
  139. </span>
  140. </div>
  141. <div id="article_lang">
  142. <div class="click_dropdown_div">
  143. <div class="click_dropdown_button">语言</div>
  144. <div class="click_dropdown_content">
  145. <div class="click_dropdown_content_inner">
  146. <a>简体中文</a>
  147. </div>
  148. </div>
  149. </div>
  150. </div>
  151. </div>
  152. </div>
  153. <div id="contents_view">
  154. <div id="contents_div" style="padding: 0 1em 0 30px;width:70vw;">
  155. <div id="contents"><?php echo $_local->gui->loading; ?>...</div>
  156. <div id="contents_toc"></div>
  157. <div id="contents_foot">
  158. <div id="contents_nav" style="display:flex;justify-content: space-between;">
  159. <div id="contents_nav_left"></div>
  160. <div id="contents_nav_right"></div>
  161. </div>
  162. <div id="contents_dicuse"></div>
  163. </div>
  164. </div>
  165. <div id="right_pannal">
  166. <div class="fun_frame">
  167. <div id = "collect_title" class="title"><?php echo $_local->gui->contents; ?></div>
  168. <div id = "toc_content" class="content" style="max-height:25vw;">
  169. </div>
  170. </div>
  171. <div class="fun_frame">
  172. <div style="display:flex;justify-content: space-between;">
  173. <div class="title"><?php echo $_local->gui->contributor; ?></div>
  174. <div class="click_dropdown_div">
  175. <div class="channel_select_button" onclick="onChannelMultiSelectStart()"><?php echo $_local->gui->select; ?></div>
  176. </div>
  177. </div>
  178. <div class='channel_select'>
  179. <button onclick='onChannelChange()'><?php echo $_local->gui->confirm; ?></button>
  180. <button onclick='onChannelMultiSelectCancel()'><?php echo $_local->gui->cancel; ?></button>
  181. </div>
  182. <div id="channal_list" class="content" style="max-height:25vw;">
  183. </div>
  184. </div>
  185. </div>
  186. </div>
  187. </div>
  188. <div id="main_view_shell">
  189. <div id="right_float_pannal">
  190. <div id="tool_bar">
  191. <span>
  192. <button id="max_right_float" class="icon_btn" onclick="max_right_float(this)">
  193. <svg class='icon'><use xlink:href='../studio/svg/icon.svg#eye_disable'></use></svg>
  194. </button>
  195. <button id="min_right_float" class="icon_btn" onclick="min_right_float(this)">
  196. <svg class='icon'><use xlink:href='../studio/svg/icon.svg#eye_disable'></use></svg>
  197. </button>
  198. </span>
  199. <span>
  200. <button id="close_right_float" class="icon_btn" onclick="close_right_float()">
  201. <svg class='icon'><use xlink:href='../studio/svg/icon.svg#eye_disable'></use></svg>
  202. </button>
  203. </span>
  204. </div>
  205. <iframe id="dict" src="../dict/index.php?builtin=true" name="dict" title="wikipali"></iframe>
  206. </div>
  207. </div>
  208. <script>
  209. $(document).ready(function(){
  210. ntf_init();
  211. click_dropdown_init();
  212. note_create();
  213. reader_load();
  214. historay_init();
  215. });
  216. window.addEventListener('scroll',winScroll);
  217. function winScroll(e){
  218. if(GetPageScroll().y>220){
  219. }
  220. else{
  221. }
  222. }
  223. //滚动条位置
  224. function GetPageScroll()
  225. {
  226. var pos=new Object();
  227. var x, y;
  228. if(window.pageYOffset)
  229. { // all except IE
  230. y = window.pageYOffset;
  231. x = window.pageXOffset;
  232. } else if(document.documentElement && document.documentElement.scrollTop)
  233. { // IE 6 Strict
  234. y = document.documentElement.scrollTop;
  235. x = document.documentElement.scrollLeft;
  236. } else if(document.body) { // all other IE
  237. y = document.body.scrollTop;
  238. x = document.body.scrollLeft;
  239. }
  240. pos.x=x;
  241. pos.y=y;
  242. return(pos);
  243. }
  244. </script>
  245. </body>
  246. </html>