From 2ebec59dfa17abffe6a637d2317444962c20fb0d Mon Sep 17 00:00:00 2001 From: James Dinh Date: Sun, 17 Jul 2022 23:55:21 -0700 Subject: [PATCH] Added email-replace --- index.html | 16 ++++++++-------- js/general.js | 42 ++++++++++++++++++++++++++++++++++++++---- 2 files changed, 46 insertions(+), 12 deletions(-) diff --git a/index.html b/index.html index e3edf42..e191565 100644 --- a/index.html +++ b/index.html @@ -574,7 +574,7 @@

However, Gilroy Hacks will use these photos for promoting purposes ONLY. We will never share your personal or private information to anyone outside the event.

- If you have a disagreement with any of the terms stated above, please contact an event organizer or email tech@gilroyhacks.com + If you have a disagreement with any of the terms stated above, please contact an event organizer or email tech (at) gilroyhacks (dot) com @@ -658,7 +658,7 @@

Aadhavan Magesh

Secretary
-
Discord: Skymon#0438
aadhavan.magesh@gmail.com
+
Discord: Skymon#0438
aadhavan.magesh (at) gmail (dot) com
@@ -669,7 +669,7 @@

Isaac Hwang

Lead Organizer
-
Discord: Fesh#5995
ihwang125@gmail.com
+
Discord: Fesh#5995
ihwang125 (at) gmail (dot) com
@@ -688,7 +688,7 @@

Vijay Kethanaboyina

Outreach Manager
-
Discord: SURPRISE!!#8662
vijaykethanaboyina@gmail.com
+
Discord: SURPRISE!!#8662
vijaykethanaboyina (at) gmail (dot) com
@@ -699,7 +699,7 @@

James Dinh

Lead Website Designer
-
Discord: wellfedbison#0607
+
Discord: wellfedbison#0607
jamesdinh77 (at) protonmail (dot) com
@@ -707,7 +707,7 @@

Clement Boiteux

Tech Support
-
Discord: Maul#8742
ezrabridger27@gmail.com
+
Discord: Maul#8742
ezrabridger27 (at) gmail (dot) com
@@ -715,7 +715,7 @@

Mark Shen

Tech Support
-
Discord: No Game No life#4534
markshen00@gmail.com
+
Discord: No Game No life#4534
markshen00 (at) gmail (dot) com
@@ -726,7 +726,7 @@

Bryce Mankovsky

Marketing Manager
-
Discord: bmank52#1664
brycemankovsky@gmail.com
+
Discord: bmank52#1664
brycemankovsky (at) gmail (dot) com
diff --git a/js/general.js b/js/general.js index c6ed31b..0eb0466 100644 --- a/js/general.js +++ b/js/general.js @@ -3,10 +3,44 @@ // document is loaded and DOM is ready document.addEventListener('DOMContentLoaded', function(){ - document.querySelectorAll('a.email-replace').forEach(elem => { - elem.href = "mailto:jamesdinh77" + "@" + "protonmail.com"; - elem.target = "_blank"; - }); + // Email replace + function setAttributes(elem, attrs) { + for(var key in attrs) { + elem.setAttribute(key, attrs[key]); + } + } + + var tech = document.getElementById("email-replace-tech"); + setAttributes(tech, {"href": "mailto:tech" + "@" + "gilroyhacks.com?subject=Gilroy Hacks", "target": "_blank"}); + tech.innerHTML = "tech" + "@" + "gilroyhacks.com"; + + var aadhavan = document.getElementById("email-replace-aadhavan"); + setAttributes(aadhavan, {"href": "mailto:aadhavan.magesh" + "@" + "gmail.com?subject=Gilroy Hacks", "target": "_blank"}); + aadhavan.innerHTML = "aadhavan.magesh" + "@" + "gmail.com"; + + var isaac = document.getElementById("email-replace-isaac"); + setAttributes(isaac, {"href": "mailto:ihwang125" + "@" + "gmail.com?subject=Gilroy Hacks", "target": "_blank"}); + isaac.innerHTML = "ihwang125" + "@" + "gmail.com"; + + var vijay = document.getElementById("email-replace-vijay"); + setAttributes(vijay, {"href": "mailto:vijaykethanaboyina" + "@" + "gmail.com?subject=Gilroy Hacks", "target": "_blank"}); + vijay.innerHTML = "vijaykethanaboyina" + "@" + "gmail.com"; + + var james = document.getElementById("email-replace-james"); + setAttributes(james, {"href": "mailto:jamesdinh77" + "@" + "protonmail.com?subject=Gilroy Hacks", "target": "_blank"}); + james.innerHTML = "jamesdinh77" + "@" + "protonmail.com"; + + var ezra = document.getElementById("email-replace-ezra"); + setAttributes(ezra, {"href": "mailto:ezrabridger27" + "@" + "gmail.com?subject=Gilroy Hacks", "target": "_blank"}); + ezra.innerHTML = "ezrabridger27" + "@" + "gmail.com"; + + var mark = document.getElementById("email-replace-mark"); + setAttributes(mark, {"href": "mailto:markshen00" + "@" + "gmail.com?subject=Gilroy Hacks", "target": "_blank"}); + mark.innerHTML = "markshen00" + "@" + "gmail.com"; + + var bryce = document.getElementById("email-replace-bryce"); + setAttributes(bryce, {"href": "mailto:brycemankovsky" + "@" + "gmail.com?subject=Gilroy Hacks", "target": "_blank"}); + bryce.innerHTML = "brycemankovsky" + "@" + "gmail.com"; // Checkbox Local Storage var i;