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_hash = '<?php echo generateAuthHash(ZM_AUTH_HASH_IPS) ?>';
|
||||||
var auth_relay = '<?php echo get_auth_relay() ?>';
|
var auth_relay = '<?php echo get_auth_relay() ?>';
|
||||||
var user = {
|
var user = <?php
|
||||||
<?php if ( $user ) { ?>
|
unset($user['Password']);
|
||||||
"Id" : "<?php echo $user['Id'] ?>",
|
echo json_encode($user);
|
||||||
"Username" : "<?php echo $user['Username'] ?>"
|
?>;
|
||||||
<?php } ?>
|
|
||||||
};
|
|
||||||
var running = <?php echo daemonCheck()?'true':'false' ?>;
|
var running = <?php echo daemonCheck()?'true':'false' ?>;
|
||||||
|
|
Loading…
Reference in New Issue