zhengkaixin 3 yıl önce
ebeveyn
işleme
7cb5bc470b

+ 0 - 9
assets/html/login/index.html

@@ -1,9 +0,0 @@
-<!DOCTYPE html>
-<html>
-	<head>
-		<meta charset="utf-8">
-		<title></title>
-	</head>
-	<body>
-	</body>
-</html>

+ 23 - 0
assets/js/language.js

@@ -0,0 +1,23 @@
+$(function(){
+	
+	function loadProperties() {
+	            jQuery.i18n.properties({//加载资浏览器语言对应的资源文件
+	                name : 'strings', //资源文件名称
+	                path : '/i18n/', //资源文件路径
+	                mode : 'map', //用Map的方式使用资源文件中的值
+	                language : 'zh-CH',
+	                callback : function() {//加载成功后设置显示内容
+	                    $('.i18n-text').each(function() {
+							console.log($(this).text())
+							
+	                        $(this).text($.i18n.prop($(this).text()));
+	                    });
+						$('.i18n-input').each(function() {
+						    $(this).value($.i18n.prop($(this).text()));
+						});
+						
+	                }
+	            });
+	        }
+			loadProperties();
+})

+ 0 - 0
assets/html/company/index.html → html/company/index.html


+ 22 - 0
html/lanhu/index.html

@@ -0,0 +1,22 @@
+<!DOCTYPE html>
+<html>
+	<head>
+		<meta charset="utf-8">
+		<title></title>
+		 
+	</head>
+	<script src="/lanhu-bootstrap/js/jquery-1.9.1.min.js"></script>
+	    <script src="/lanhu-bootstrap/js/jquery.i18n.properties.js"></script>
+	    <script src="/lanhu-bootstrap/assets/js/language.js"></script>
+	<body>
+		<h1>1111</h1>
+		 <select id="language">
+		                <option value="zh-CN">中文简体</option>
+		                <option value="en">English</option>
+		            </select>
+		<div>
+			<span   class="i18n-text">signOut</span>
+		    <input type="search"  selectname="searchPlaceholder" selectattr="placeholder">
+		</div>
+	</body>
+</html>

+ 0 - 0
assets/html/lanhu/index.html → html/login/index.html


+ 1 - 0
i18n/strings_en.properties

@@ -0,0 +1 @@
+signOut=Login Out

+ 1 - 0
i18n/strings_zh-CH.properties

@@ -0,0 +1 @@
+signOut=退出

+ 3 - 9
index.html

@@ -1,9 +1,3 @@
-<!DOCTYPE html>
-<html>
-	<head>
-		<meta charset="utf-8">
-		<title></title>
-	</head>
-	<body>
-	</body>
-</html>
+<script>
+window.location.href="html/lanhu/index.html"
+</script>