<?php 
if (Auth::check()) {
    ?>
<script type="text/javascript">
$(document).ready(function(){  
  var   authCheck = <?php 
    if (Auth::check()) {
        echo "1";
    } else {
        echo "0";
    }
    ?>
;
    if(authCheck == '1'){
        var notification_karmanote = <?php 
    echo KarmaHelper::UnreadKarmaNote();
    ?>
;
        var notification_karmameeting = <?php 
    echo KarmaHelper::UnreadMeetingRequest();
    ?>
;
    $("#notification_karmanote").html(notification_karmanote);
    $("#notification_karmameeting").html(notification_karmameeting);
      }
     
    });

</script>
<?php 
}