Blogger Information
Blog 21
fans 0
comment 0
visits 12421
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
可以进行数据录入的简历表
中天行者
Original
742 people have browsed it
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>练习</title>
  6. <style>
  7. tr {
  8. height: 20px;
  9. }
  10. table, th, tr, td {
  11. margin: 0;
  12. padding: 0;
  13. border: 1px solid grey;
  14. border-spacing: 0;
  15. }
  16. table {
  17. width: 800px;
  18. margin: auto;
  19. }
  20. .title-left {
  21. font-weight: bold;
  22. background-color: #d3e9f5;
  23. }
  24. .color_blue {
  25. background-color: #b4e2f6;
  26. }
  27. .twenty-five_per {
  28. width: 25%;
  29. }
  30. .color_white{
  31. background-color: white;
  32. }
  33. input {
  34. padding: 0;
  35. border: none;
  36. z-index: 10;
  37. min-height: 100%;
  38. width: 90%;
  39. outline: none;
  40. border-spacing: 0;
  41. }
  42. #sex>div{
  43. min-height: 100%;
  44. min-width: 100%;
  45. }
  46. #sex>div>input{
  47. width: 10px ;
  48. }
  49. #number{
  50. min-width: 200px;
  51. }
  52. #image{
  53. max-height: 161px;
  54. }
  55. </style>
  56. </head>
  57. <body>
  58. <form action="">
  59. <table>
  60. <tr style="border-top: none;border-left: none;border-right: none">
  61. <th colspan="5" class="title-left color_white" height="60px" style="font-size: 30px;">求&ensp;职&ensp;简&ensp;历&ensp;表</th>
  62. </tr>
  63. <tr>
  64. <td colspan="5" class="title-left">------基本资料------</td>
  65. </tr>
  66. <tr>
  67. <td>姓名:</td>
  68. <td id="name">马小姐</td>
  69. <td>性别:</td>
  70. <td id="sex"></td>
  71. <td rowspan="7" style="width:20%" id="image"></td>
  72. </tr>
  73. <tr>
  74. <td>学历:</td>
  75. <td id="xueli">中专</td>
  76. <td>身高:</td>
  77. <td id="height">160cm</td>
  78. </tr>
  79. <tr>
  80. <td>籍贯:</td>
  81. <td id="jiguan">广东</td>
  82. <td>出生年月:</td>
  83. <td id="birthday">1991-12-01</td>
  84. </tr>
  85. <tr>
  86. <td>毕业院校</td>
  87. <td style="width: 480px" colspan="3" id="school">汕头学院</td>
  88. </tr>
  89. <tr>
  90. <td>专业</td>
  91. <td style="width: 480px" colspan="3 " id="zhuanye">管理学=>会计</td>
  92. </tr>
  93. <tr>
  94. <td>工作经验:</td>
  95. <td id="jingyan"></td>
  96. <td>目前年薪:</td>
  97. <td id="nianxin">保密/年</td>
  98. </tr>
  99. <tr>
  100. <td>有效证件:</td>
  101. <td id="card">身份证</td>
  102. <td>证件号码:</td>
  103. <td id="number" > 123455612345123456</td>
  104. </tr>
  105. <tr>
  106. <th colspan="5" class="title-left color_blue"></th>
  107. </tr>
  108. <tr>
  109. <td colspan="5" class="title-left">------求职意向------</td>
  110. </tr>
  111. <tr class="color_blue">
  112. <td>求职意向</td>
  113. <td colspan="4" id="gangwei">出纳,会计文员</td>
  114. </tr>
  115. <tr>
  116. <td>求职地区</td>
  117. <td colspan="2" style="width:40%" id="area">罗湖</td>
  118. <td>工资待遇</td>
  119. <td id="gongzhi">面议</td>
  120. </tr>
  121. <tr>
  122. <td height="80px">自我评价</td>
  123. <td height="80px" colspan="4" id="comment">
  124. 将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行
  125. </td>
  126. </tr>
  127. <tr>
  128. <th colspan="5" class="title-left color_blue"></th>
  129. </tr>
  130. <tr>
  131. <td colspan="5" class="title-left">------教育培训------</td>
  132. </tr>
  133. <tr>
  134. <td class="twenty-five_per">起止时间</td>
  135. <td class="twenty-five_per">就读院校</td>
  136. <td class="twenty-five_per">主修专业</td>
  137. <td colspan="2" class="twenty-five_per">学历</td>
  138. </tr>
  139. <tr>
  140. <td class="twenty-five_per" id="date">2009.09~2012.07</td>
  141. <td class="twenty-five_per" id="school1">华科附属职业学院</td>
  142. <td class="twenty-five_per" id="zhuanye1">会计电算化</td>
  143. <td colspan="2" class="twenty-five_per" id="xueli1">中专</td>
  144. </tr>
  145. <tr>
  146. <th colspan="5" class="title-left color_blue"></th>
  147. </tr>
  148. <div>
  149. <tr>
  150. <td colspan="5" class="title-left">------工作经验(1)------</td>
  151. </tr>
  152. <tr>
  153. <td class="twenty-five_per">就职公司</td>
  154. <td class="twenty-five_per" id="company">XXXX电器公司</td>
  155. <td class="twenty-five_per">公司行业</td>
  156. <td colspan="2" class="twenty-five_per" id="hangye">其它</td>
  157. </tr>
  158. <tr>
  159. <td class="twenty-five_per">就职时间</td>
  160. <td class="twenty-five_per" id="start_end">2011年12月至今</td>
  161. <td class="twenty-five_per">就职部门</td>
  162. <td colspan="2" class="twenty-five_per" id="bumen">财务部</td>
  163. </tr>
  164. <tr>
  165. <td class="twenty-five_per">公司性质</td>
  166. <td class="twenty-five_per" id="xingzhi">其它</td>
  167. <td class="twenty-five_per">就职职位</td>
  168. <td colspan="2" class="twenty-five_per " id="zhiwei">出纳</td>
  169. </tr>
  170. </div>
  171. <tr>
  172. <td height="80px">工作描述</td>
  173. <td height="80px" colspan="4" id="description">
  174. 将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行将word-break属性设置为break-all,实现文字的自动换行
  175. </td>
  176. </tr>
  177. <tr>
  178. <th colspan="5" class="title-left color_blue"></th>
  179. </tr>
  180. <tr>
  181. <td colspan="5" class="title-left">------联系方式------</td>
  182. </tr>
  183. <tr>
  184. <td>联系电话</td>
  185. <td colspan="4" id="dianhua">123213123</td>
  186. </tr>
  187. <tr>
  188. <td>手机</td>
  189. <td colspan="4" id="phone">12345667777</td>
  190. </tr>
  191. <tr>
  192. <td>email</td>
  193. <td colspan="4" id="email">1112222@qq.com</td>
  194. </tr>
  195. </table>
  196. </form>
  197. <script>
  198. // localStorage.clear()
  199. var objStorage = {
  200. 'name': '姓名',
  201. 'sex': '性别',
  202. 'image': '头像',
  203. 'xueli': '学历',
  204. 'height': '身高',
  205. 'birthday': '生日',
  206. 'jiguan': '籍贯',
  207. 'school': '毕业院校',
  208. 'zhuanye': '专业',
  209. 'jingyan': '工作经验',
  210. 'nianxin': '年薪',
  211. 'card': '证件类型',
  212. 'number': '证件号码',
  213. 'gangwei': '岗位',
  214. 'area': '求职地区',
  215. 'gongzhi': '期望薪资',
  216. 'comment': '自我评价',
  217. 'date': '学习日期',
  218. 'school1': '学校',
  219. 'zhuanye1': '专业',
  220. 'xueli1': '学历',
  221. 'company': '公司名称',
  222. 'hangye': '所属行业',
  223. 'start_end': '起止日期',
  224. 'bumen': '部门',
  225. 'xingzhi': '薪资',
  226. 'zhiwei': '职务',
  227. 'description': '工作描述',
  228. 'dianhua': '电话',
  229. 'phone': '手机',
  230. 'email': '邮箱'
  231. };
  232. var e ;
  233. Object.keys(objStorage).forEach(function (v, i) {
  234. //获取当前td元素
  235. var td = document.getElementById(v);
  236. td.style.cssText="color:#3e0909;font-size:15px;font-weight:normal"
  237. if(v==='image') td.style.cssText="min-width:120px"
  238. // var value = window.localStorage.getItem(v);
  239. //不判断td是否存在 会报错Cannot set properties of null (setting 'onclick')
  240. // 因为页面加载时会把事件绑定在元素上,如果加载时没有找到事件挂载的元素就会报这个错
  241. if(td){
  242. var value = localStorage.getItem(v);
  243. if(value){
  244. if(v==='image'){
  245. value="<img src='"+ value +"' width='100%' height='161px' >";
  246. }
  247. td.innerHTML= value;
  248. }
  249. td.onclick = function () {
  250. var inp = "input";
  251. var type = "text";
  252. if(v==="image"){
  253. type="file";
  254. }else if(v==="sex"){
  255. type = "radio"
  256. }else if(v==="email"){
  257. type = "email"
  258. }else if(v==="birthday"){
  259. type = "date"
  260. }
  261. e = inputHtml(inp,v,type);
  262. if (this.childNodes.length > 0) {
  263. this.childNodes[0].remove();
  264. }
  265. if(v==="sex"){
  266. e= inputHtml("div",'div','');
  267. e.append(inputHtml(inp,v,type,'男'))
  268. e.append("男");
  269. e.append(inputHtml(inp,v,type,'女'));
  270. e.append("女");
  271. e.append(inputHtml(inp,v,type,'保密'));
  272. e.append("保密");
  273. }
  274. e.onclick=function(event){
  275. event.stopPropagation();
  276. };
  277. var _this = this;
  278. _this.append(e);
  279. e.focus();
  280. if(v==="image"){
  281. e.onchange = function () {
  282. var imgs= document.createElement("img");
  283. imgs.src= window.URL.createObjectURL(e.files[0]);
  284. imgs.style.cssText="width:100%;max-height:161px"
  285. _this.replaceChild(imgs,e);
  286. localStorage.setItem(v,imgs.src);
  287. }
  288. }else if(v==="sex"){
  289. var sexValueE=document.getElementsByName("sex");
  290. for(var i = 0;i<sexValueE.length;i++){
  291. sexValueE[i].onclick=function(){
  292. _this.innerHTML=this.value;
  293. localStorage.setItem(v,this.value);
  294. }
  295. }
  296. }
  297. else{
  298. e.onclick=function(event){
  299. event.stopPropagation();
  300. };
  301. e.onchange = function () {
  302. if(e.value.length>0)td.innerHTML = e.value;
  303. window.localStorage.setItem(v, e.value)
  304. }
  305. }
  306. }
  307. }
  308. });
  309. //创建 元素
  310. function inputHtml(e,v,type,value='') {
  311. var element = document.createElement(e)
  312. if(type==="radio" && v==="sex"){
  313. element.value = value
  314. if (localStorage.getItem(v)===value) {
  315. element.checked=true;
  316. }
  317. }else{
  318. element.id = "id_" + v;
  319. }
  320. element.name = v;
  321. element.type = type;
  322. element.placeholder = '请填写' + objStorage[v];
  323. return element;
  324. }
  325. window.onload=function () {
  326. Object.keys(objStorage).forEach(function (v, i) {
  327. });
  328. }
  329. </script>
  330. </body>
  331. </html>
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post