forked from Jaskey/easyresume
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
89 lines (70 loc) · 3.23 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
<!DOCTYPE html>
<html>
<head>
<meta http-equiv='Content-type' content='text/html; charset=utf-8'>
<meta http-equiv="Cache-control" content="public">
<meta name="viewport" content="width=device-width,initial-scale=1" />
<title>easy resume</title>
<link rel="stylesheet" href="src/stylesheet/resume.css" type="text/css"></link>
<link rel="stylesheet" media="screen and (min-width: 1020px)" href="src/stylesheet/resume_hdp.css" type="text/css"></link>
<link rel="stylesheet" media="screen and (max-width: 1019px) and (min-width: 451px)" href="src/stylesheet/resume_mdp.css" type="text/css"></link>
<link rel="stylesheet" media="screen and (max-width: 450px)" href="src/stylesheet/resume_ldp.css" type="text/css"></link>
<script src="https://lib.sinaapp.com/js/jquery/1.9.1/jquery-1.9.1.min.js"></script>
<script src="react15/react.js"></script>
<script src="react15/react-dom.js"></script>
<script src="react15/browser.min.js"></script>
<script type="text/babel" src="src/js/basecomponents.js"></script>
<script type="text/babel" src="src/js/resumecomponents.js"></script>
<style>
div#defaultMsg {
display:none;
min-width: 500px;
height: 100%;
font-size: 20px;
line-height: 3;
padding: 50px;
}
div#defaultMsg code{
border-radius: 10px;
background: #EEE;
padding: 15px;
}
</style>
</head>
<body>
<div id="container">
<div id="defaultMsg">
<h2>EasyResume初始化错误</h2>
<p>
如果你看到这个页面,证明页面初始化失败了,这很可能是由于你直接在本地打开简历的缘故。EasyResume需要用HTTP的方法访问才能初始化。若你已经安装了python, 可以尝试:
</p>
<code>python -m SimpleHTTPServer</code>
<p>来启动HTTP服务,然后浏览器中输入<a href="http://localhost:8000">http://localhost:8000</a>去查看resume.html</p>
<h2>EasyResume initiailized error</h2>
<p>
If you can see this, EasyResume is not working right. This is probably because you're viewing this on your file system instead of a web server. If you have installed python, try running
</p>
<code>python -m SimpleHTTPServer</code>
<p>and going to <a href="http://localhost:8000">http://localhost:8000</a> then check resume.html</p>
</div>
</div>
<script type="text/babel">
$.getJSON("resume.json",[])
.done(function(data){
console.log('[done][resume.json read successfully]',data);
var json = data;
ReactDOM.render(<div><Resume json={json}/></div>,document.getElementById('container'));
var name = json.name;
if(name) document.title='EasyResume-'+name;
}).fail(function(jqxhr, textStatus, error ){
var err = textStatus + ", " + error;
console.error( "[Request resume.json Failed]: " + err );
$('#defaultMsg').html("加载/解析resume.json文件错误 :"+textStatus+"。请确认json文件存在并且配置格式正确。<br> error :" +error);
});
//一秒后显示默认的提示区域,如果正常初始化,$('#defaultMsg')将不存在,故没有作用
window.setTimeout(function(){
$('#defaultMsg').show();
},1000)
</script>
</body>
</html>