mirror of
https://github.com/titanscouting/tra-analysis.git
synced 2024-12-27 01:59:08 +00:00
no but this ugly html hack should
This commit is contained in:
parent
3a5629f0ba
commit
4529ee32e2
@ -31,7 +31,7 @@
|
|||||||
<table id="profileupd">
|
<table id="profileupd">
|
||||||
<tr class="profupdopt">
|
<tr class="profupdopt">
|
||||||
<td>
|
<td>
|
||||||
Username: <input type="text" name="NewDN" value="" id="newDN">
|
Username: <span contenteditable="true" id="newDN"></span>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<input type="button" name="upun" value="Update Username" onclick="updun();">
|
<input type="button" name="upun" value="Update Username" onclick="updun();">
|
||||||
@ -39,7 +39,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="profileupdopt">
|
<tr class="profileupdopt">
|
||||||
<td>
|
<td>
|
||||||
Email: <input type="text" name="NewEM" value="" id="newEM">
|
Email: <span contenteditable="true" id="newEM"></span>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<input type="button" name="updem" value="Update Email" onclick="updem();">
|
<input type="button" name="updem" value="Update Email" onclick="updem();">
|
||||||
|
@ -27,7 +27,7 @@ window.onload = function() {
|
|||||||
if (user != null) {
|
if (user != null) {
|
||||||
if (user.displayName != null) {
|
if (user.displayName != null) {
|
||||||
document.getElementById('status').innerHTML = "You are signed in as: " + user.displayName;
|
document.getElementById('status').innerHTML = "You are signed in as: " + user.displayName;
|
||||||
document.getElementById('newDN').value = user.displayName;
|
document.getElementById('newDN').innerHTML = user.displayName;
|
||||||
} else if (user.email != null) {
|
} else if (user.email != null) {
|
||||||
document.getElementById('status').innerHTML = "You are signed in as: " + user.email;
|
document.getElementById('status').innerHTML = "You are signed in as: " + user.email;
|
||||||
} else if (user.phoneNumber != null) {
|
} else if (user.phoneNumber != null) {
|
||||||
@ -36,7 +36,7 @@ window.onload = function() {
|
|||||||
document.getElementById('status').innerHTML = "You are signed in.";
|
document.getElementById('status').innerHTML = "You are signed in.";
|
||||||
}
|
}
|
||||||
if (user.email != null) {
|
if (user.email != null) {
|
||||||
document.getElementById('newEM').value = user.email;
|
document.getElementById('newEM').innerHTML = user.email;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
window.location.replace('../');
|
window.location.replace('../');
|
||||||
@ -65,9 +65,9 @@ function deleteAccount() {
|
|||||||
function updun() {
|
function updun() {
|
||||||
var user = firebase.auth().currentUser;
|
var user = firebase.auth().currentUser;
|
||||||
user.updateProfile({
|
user.updateProfile({
|
||||||
displayName: document.getElementById('newDN').value,
|
displayName: document.getElementById('newDN').innerHTML,
|
||||||
}).then(function() {
|
}).then(function() {
|
||||||
document.getElementById('newDN').value = firebase.auth().currentUser.displayName;
|
document.getElementById('newDN').innerHTML = firebase.auth().currentUser.displayName;
|
||||||
document.getElementById('status').innerHTML = "You are signed in as: " + firebase.auth().currentUser.displayName;
|
document.getElementById('status').innerHTML = "You are signed in as: " + firebase.auth().currentUser.displayName;
|
||||||
}).catch(function(error) {
|
}).catch(function(error) {
|
||||||
alert("there was a problem: " + error)
|
alert("there was a problem: " + error)
|
||||||
@ -76,10 +76,10 @@ function updun() {
|
|||||||
|
|
||||||
function updem() {
|
function updem() {
|
||||||
var user = firebase.auth().currentUser;
|
var user = firebase.auth().currentUser;
|
||||||
user.updateEmail(document.getElementById('newEM').value).then(function() {
|
user.updateEmail(document.getElementById('newEM').innerHTML).then(function() {
|
||||||
if (user.displayName != null) {
|
if (user.displayName != null) {
|
||||||
document.getElementById('status').innerHTML = "You are signed in as: " + user.displayName;
|
document.getElementById('status').innerHTML = "You are signed in as: " + user.displayName;
|
||||||
document.getElementById('newDN').value = user.displayName;
|
document.getElementById('newDN').innerHTML = user.displayName;
|
||||||
} else if (user.email != null) {
|
} else if (user.email != null) {
|
||||||
document.getElementById('status').innerHTML = "You are signed in as: " + user.email;
|
document.getElementById('status').innerHTML = "You are signed in as: " + user.email;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user