Difference between revisions of "Template:HSNU-TAIPEI/members js"
(Created page with "var generateHeading2 = function(headingContent) { var h2 = document.createElement('h2'); var content = document.createTextNode(headingContent); h2.appendChild(content); retu...") |
|||
(40 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
+ | <html> | ||
+ | <script> | ||
+ | |||
var generateHeading2 = function(headingContent) { | var generateHeading2 = function(headingContent) { | ||
var h2 = document.createElement('h2'); | var h2 = document.createElement('h2'); | ||
Line 18: | Line 21: | ||
var justifiedName = ""; | var justifiedName = ""; | ||
for(var i = 0; i < length; i++) { | for(var i = 0; i < length; i++) { | ||
− | if(personName[i] | + | var check = true; |
− | + | if(personName[i] == ' ' || personName[i] == '-') { | |
+ | check = false; | ||
} | } | ||
+ | if(check) { | ||
+ | justifiedName += personName[i]; | ||
+ | } | ||
} | } | ||
return justifiedName; | return justifiedName; | ||
}; | }; | ||
− | var generatePersonImg = function(personName) { | + | var generatePersonImg = function(personName, personSrc) { |
var justifiedName = justifyPersonName(personName); | var justifiedName = justifyPersonName(personName); | ||
− | var source = "../ | + | var source = "https://static.igem.org/mediawiki/2015/" + personSrc + "/HSNU-TAIPEI_" + justifiedName + ".jpg"; |
return '<img src="' + source + '">'; | return '<img src="' + source + '">'; | ||
}; | }; | ||
− | var generatePersonFigure = function(personName | + | var generatePersonFigure = function(personName) { |
var figure = "<figure>"; | var figure = "<figure>"; | ||
figure += generatePersonName(personName); | figure += generatePersonName(personName); | ||
− | |||
figure += "</figure>"; | figure += "</figure>"; | ||
return figure; | return figure; | ||
Line 41: | Line 47: | ||
var generateProfile = function(person) { | var generateProfile = function(person) { | ||
var personName = person["Name"], | var personName = person["Name"], | ||
− | + | personSrc = person["Source"]; | |
var profile = document.createElement('div'); | var profile = document.createElement('div'); | ||
− | var content = generatePersonImg(personName); | + | var content = generatePersonImg(personName, personSrc); |
− | + | content += generatePersonFigure(personName) | |
profile.setAttribute('class', 'profile'); | profile.setAttribute('class', 'profile'); | ||
profile.innerHTML = content; | profile.innerHTML = content; | ||
Line 78: | Line 84: | ||
sectionName: "Teacher", | sectionName: "Teacher", | ||
persons: [ | persons: [ | ||
− | { Name:"Su Shu-Ching", | + | { Name:"Su Shu-Ching", Source: "8/88" }, |
− | { Name:"Wu Tzu-Yun", | + | { Name:"Wu Tzu-Yun", Source: "9/9f" }, |
+ | { Name: "Chen Jhih-Sheng", Source: "b/b4" }, | ||
+ | { Name: "Chiang Ching-Chao", Source: "8/80" }, | ||
+ | { Name: "Hsieh Hui-Lin", Source: "3/3b" }, | ||
+ | { Name: "Hsieh Jui-Lin", Source: "0/0a" }, | ||
+ | { Name: "Huang Tzung-Hsien", Source: "5/58" }, | ||
+ | { Name: "Lai Hsiang-Ju", Source: "6/69" }, | ||
+ | { Name: "Lin Chun-Wei", Source: "6/64" }, | ||
+ | { Name: "Lin Yi-Hsiung", Source: "a/a2" }, | ||
+ | { Name: "Pan Guan-Chi", Source: "a/a9" }, | ||
+ | { Name: "Wang Shih-Haur", Source: "9/95" }, | ||
+ | { Name: "Chen Chao-Chin", Source: "2/21" }, | ||
+ | { Name: "Yeh Hua-Yu", Source: "3/35" }, | ||
+ | { Name: "Pan Su-Chen", Source: "0/0b" }, | ||
] | ] | ||
}; | }; | ||
Line 86: | Line 105: | ||
sectionName: "Experiment", | sectionName: "Experiment", | ||
persons: [ | persons: [ | ||
− | + | { Name: "Chang Ko-Yu", Source: "b/bc" }, | |
− | + | { Name: "Chu Yi-Chia", Source: "5/5b" }, | |
− | + | { Name: "Lin Sheng", Source: "0/09" }, | |
− | + | { Name: "Shen Yu-Chun", Source: "9/9d" }, | |
− | + | { Name: "Zhao Ming-Cheng", Source: "f/fa" }, | |
+ | {Name:"Lee Wen-Ti",Source:"2/24"}, | ||
+ | { Name: "Chang Yu-Ting", Source: "8/86" }, | ||
+ | { Name: "Chen Sheng-Yuan", Source: "a/a1" }, | ||
+ | { Name: "Chi Ying-Cheng", Source: "1/12" }, | ||
+ | { Name: "Hsu Chia-Yang", Source: "8/84" }, | ||
+ | { Name: "Lee Chang-Lung", Source: "4/47" }, | ||
+ | { Name: "Leng Yi-Yan", Source: "4/4a" }, | ||
+ | { Name: "Chu Wei-Min", Source: "c/ca" }, | ||
+ | { Name: "Su Chin-Fong", Source: "a/a3" }, | ||
+ | { Name: "Lee Min-Chou", Source: "b/b6" }, | ||
+ | { Name: "Han Yun-An", Source: "e/e9" }, | ||
+ | { Name: "Chang I", Source: "a/a6" }, | ||
] | ] | ||
}; | }; | ||
Line 97: | Line 128: | ||
sectionName: "Human Practice", | sectionName: "Human Practice", | ||
persons: [ | persons: [ | ||
+ | {Name:"Chang Chun-Chieh",Source:"0/08"}, | ||
+ | {Name:"Tsai Min-Hao",Source:"7/74"}, | ||
+ | {Name:"Wang Tz-Tung",Source:"5/56"}, | ||
+ | {Name:"Liu Pin-Lan",Source:"3/39"}, | ||
+ | {Name:"Lai Ching-Lan",Source:"4/46"}, | ||
+ | {Name:"Hsieh Wan-Hsuan",Source:"0/0f"}, | ||
+ | {Name:"Wang Ying-Chyi",Source:"b/bd"}, | ||
+ | {Name:"Wu Chia-Yang",Source:"4/42"}, | ||
+ | {Name:"Lee Ming-Jhen",Source:"0/06"}, | ||
+ | { Name: "Shen Yu-Kai", Source: "b/b8" }, | ||
+ | { Name: "Huang Chi-Hung", Source: "2/27" }, | ||
+ | { Name: "Lee Po-Yen", Source: "a/a3" }, | ||
+ | { Name: "Chang Chin-Yuan", Source: "0/0d" }, | ||
+ | { Name: "Chou Nai-Ching", Source: "8/88" }, | ||
+ | { Name: "Ou Hsu-Feng", Source: "d/da" }, | ||
+ | { Name: "Wu Sheng-Yuan", Source: "5/50" }, | ||
+ | { Name: "Lu Yi-Wen", Source: "8/8c" }, | ||
+ | { Name: "Chang Jen-Han", Source: "c/c7" }, | ||
+ | { Name: "Cheng Hao-Sheng", Source: "f/fd" }, | ||
+ | { Name: "Hong Jun-Cheng", Source: "e/e2" }, | ||
+ | { Name: "Lee Ching-Yen", Source: "9/94" }, | ||
+ | { Name: "Wu Hsiu", Source: "3/38" }, | ||
] | ] | ||
}; | }; | ||
Line 109: | Line 162: | ||
sectionName: "Wiki", | sectionName: "Wiki", | ||
persons: [ | persons: [ | ||
− | { Name:" | + | { Name:"Yu Hsiu-Ting", Role:"Student", Source:"c/c6" }, |
− | + | { Name:"Shi Cheng-Yu", Role:"Student", Source:"d/d1" }, | |
− | { Name:"Shi Cheng-Yu", Role:"Student" }, | + | { Name:"Hung Chi-Heng", Role:"Student", Source:"f/f7" } |
− | { Name:" | + | |
] | ] | ||
}; | }; | ||
Line 120: | Line 172: | ||
addSection(section_teacher); | addSection(section_teacher); | ||
addSection(section_experiment); | addSection(section_experiment); | ||
+ | addSection(section_human_practice); | ||
addSection(section_wiki); | addSection(section_wiki); | ||
+ | |||
+ | |||
+ | |||
+ | </script> | ||
+ | </html> |
Latest revision as of 02:11, 19 September 2015