Also, I am using console.log in my javascript files this is my function
function eventData(){
var Email;
var newemail;
firebase.auth().onAuthStateChanged(function(user) {
if (user) {
Email = user.email;
newemail = Email.replace(".com","")
console.log(" Email in event page is : " + Email);
console.log(" new Email in event page is : " + newemail);
}
<body onLoad="eventData()">
<img src="img/logo.png" style="width: 90px; height: 90px; margin-
left: 65px; margin-top: 18px"/>
<span><img src="img/soldoutsa.png" style="width: 120px; height:
120px; margin-top: 18px"/></span>
<button class="button1" id="pulse" onClick="logout()" style="margin-
top: 10px; margin-left: 1080px"><img src="img/logout.png"
width="30px"
height="30px"></button>
<p style="color: #999999; margin-left: 65px; font-size: 40px; font-
weight: 600; margin-top: 5px; font-family: 'Gill Sans Nova Light';
margin-top: 15px">Events</p>
<p style="color: #999999; margin-left: 65px; font-weight: 600; font-
size: 30px; font-family: 'Gill Sans Nova Light'; margin-top: -20px;
margin-top: 10px">Your events</p>
<div class="scroll scroll2">
<div class="content">
<table id="tbl_users_list" border="1">
<tr>
<td>#ID</td>
<td>NAME</td>
</tr>
This is my code for javascript and HTML. Please help me out
..............................................................
It just doesn't go into the condition
if (user)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.