ソースを参照

多语言multi-language #26

Bhikkhu-Kosalla 5 年 前
コミット
cf75d3fcde

+ 7 - 7
app/pcdl/reader.php

@@ -352,7 +352,7 @@ else{
 				if($tocMinLevel==0){
 					if($value["level"]>$tocMaxLevel){
 						$tocMinLevel = $value["level"];
-						$tocHtml .= "<div class='toc_title2 {$classCurrToc}{$classCurrTocTitle2}'><a href='reader.php?view=chapter&book={$book}&para={$value["paragraph"]}'>{$value["toc"]}</a></div>";
+						$tocHtml .= "<div class='toc_title2 {$classCurrToc}{$classCurrTocTitle2}'><a href='reader.php?view=chapter&book={$book}&para={$value["paragraph"]}&display={$_display}'>{$value["toc"]}</a></div>";
 					}
 					else{
 						$tocHtml .= "</div></div><div class='toc_1 {$classCurrToc}'>";
@@ -366,7 +366,7 @@ else{
 						$tocHtml .= "<div  class='toc_1_title'>{$value["toc"]}</div><div class='toc_2 $classCurrToc2' >";
 					}
 					else if($value["level"] == $tocMinLevel){
-						$tocHtml .= "<div class='toc_title2 {$classCurrToc}{$classCurrTocTitle2}'><a href='reader.php?view=chapter&book={$book}&para={$value["paragraph"]}'>{$value["toc"]}</a></div>";
+						$tocHtml .= "<div class='toc_title2 {$classCurrToc}{$classCurrTocTitle2}'><a href='reader.php?view=chapter&book={$book}&para={$value["paragraph"]}&display={$_display}'>{$value["toc"]}</a></div>";
 					}
 				}
 
@@ -430,11 +430,11 @@ else{
 					$next_para_link .= "</span></a>";
 				}
 				else{
-					$next_para_link = "没有查询到标题";
+					$next_para_link = $_local->gui->text_without_title;
 				}
 			}
 			else{
-				$next_para_link = "没了";
+				$next_para_link = $_local->gui->end_of_text;
 			}
 
 			if($par_prev != -1){
@@ -446,11 +446,11 @@ else{
 					$prev_para_link .= "</span><span id='para_nav_prev'>{$FetchPara[0]["toc"]}</span></a>";
 				}
 				else{
-					$prev_para_link = "没有查询到标题";
+					$prev_para_link = $_local->gui->text_without_title;
 				}
 			}
 			else{
-				$prev_para_link = "没了";
+				$prev_para_link = $_local->gui->begin_of_text;
 			}			
 		}
 
@@ -464,7 +464,7 @@ else{
 	}
 
 	if($currLevel<$tocMinLevel){
-		echo "请选择章节";
+		echo $_local->gui->chapter_select;
 	}
 	else{
 	//上一级

+ 1 - 0
app/public/lang/default.json

@@ -469,6 +469,7 @@
 		"text_without_title": "text without title",
 		"end_of_text": "No Prev",
 		"begin_of_text": "No Next",
+		"chapter_select": "Please choose a chapter in the left sidebar",
 		"": ""
 	},
 	"grammastr": [

+ 1 - 0
app/public/lang/en.json

@@ -468,6 +468,7 @@
 		"text_without_title": "text without title",
 		"end_of_text": "No Prev",
 		"begin_of_text": "No Next",
+		"chapter_select": "Please choose a chapter in the left sidebar",
 		"": ""
 	},
 	"grammastr": [

+ 1 - 0
app/public/lang/my.json

@@ -468,6 +468,7 @@
 		"text_without_title": "text without title",
 		"end_of_text": "No Prev",
 		"begin_of_text": "No Next",
+		"chapter_select": "Please choose a chapter in the left sidebar",
 		"": "",
 		"": ""
 	},

+ 1 - 0
app/public/lang/si.json

@@ -473,6 +473,7 @@
 		"text_without_title": "text without title",
 		"end_of_text": "No Prev",
 		"begin_of_text": "No Next",
+		"chapter_select": "Please choose a chapter in the left sidebar",
 		"": "",
 		"": ""
 	},

+ 1 - 0
app/public/lang/zh-cn.json

@@ -471,6 +471,7 @@
 		"text_without_title": "有正文缺标题",
 		"end_of_text": "到底啦",
 		"begin_of_text": "到顶啦",
+		"chapter_select": "请在左侧边栏中选择章节",
 		"": ""
 	},
 	"grammastr": [

+ 1 - 0
app/public/lang/zh-tw.json

@@ -470,6 +470,7 @@
 		"text_without_title": "有正文缺標題",
 		"end_of_text": "到底啦",
 		"begin_of_text": "到頂啦",
+		"chapter_select": "請在左側邊欄中選擇章節",
 		"": ""
 	},
 	"grammastr": [

+ 3 - 3
app/studio/index_pc.php

@@ -123,18 +123,18 @@ require_once '../studio/index_head.php';
 									<input type="input" name="op" value="create" />
 									<textarea id="project_new_res_data" rows="3" cols="18" name="data"></textarea><br>
 								</div>
-								<input type="submit" value="立即编辑" />
+								<input type="submit" value=<?php  echo $_local->gui->edit_now?> />
 							</form>
 							<!--
 							<button onclick="book_res_edit_now(1)">
 								<svg class="icon"><use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="svg/icon.svg#ic_assignment_returned"></use></svg>
 								<?php echo $module_gui_str['editor_wizard']['1013'];?>
 							</button>
-							-->
+							
 							<button  onclick="explorer_res_add_to_list()">
 								<svg class="icon" viewBox="0 0 24 24" id="ic_add_shopping_cart_24px" ><path d="M11 9h2V6h3V4h-3V1h-2v3H8v2h3v3zm-4 9c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zm10 0c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2zm-9.83-3.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.86-7.01L19.42 4h-.01l-1.1 2-2.76 5H8.53l-.13-.27L6.16 6l-.95-2-.94-2H1v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.13 0-.25-.11-.25-.25z"></path></svg>
 								添加到编辑列表
-							</button>
+							</button>-->
 						</div>
 					</div>
 					<div id="wizard_palicannon_par_select_text_body">