use json_encode($User) instead of specific elements. For some reason $user['Id'] isn't defined for me atm.
This commit is contained in:
parent
a1364a2b2b
commit
3d01008510
|
@ -83,10 +83,8 @@ var imagePrefix = "<?php echo '?view=image&eid=' ?>";
|
|||
|
||||
var auth_hash = '<?php echo generateAuthHash(ZM_AUTH_HASH_IPS) ?>';
|
||||
var auth_relay = '<?php echo get_auth_relay() ?>';
|
||||
var user = {
|
||||
<?php if ( $user ) { ?>
|
||||
"Id" : "<?php echo $user['Id'] ?>",
|
||||
"Username" : "<?php echo $user['Username'] ?>"
|
||||
<?php } ?>
|
||||
};
|
||||
var user = <?php
|
||||
unset($user['Password']);
|
||||
echo json_encode($user);
|
||||
?>;
|
||||
var running = <?php echo daemonCheck()?'true':'false' ?>;
|
||||
|
|
Loading…
Reference in New Issue