Profile Page per user

The profile view of the user logged-in works well. However, i’m having problems in creating the user profile view for the other users.

I have separate Discover page where it displays all of the users that exists on the Mongo Collection and I want to be to view the person’s profile when I click on their link. However, it just shows the user logged in information on the profile page instead of the person’s I clicked.

 <template name="discover">
    {{#if currentUser}}
   <div class="container">
       <h1> Discover </h1>
    <div class="discover-content">
       {{#each users}} 
       <img src="/defaultProfilePhoto.png" class="profile-img" >   

         <a href="profile"> {{username}} </a> <br>
          {{profile.fullName}} <br>
          {{profile.gender}}, {{profile.age}}
     users: function() {
         return Meteor.users.find().fetch();

Can you please wrap your code in lines with triple backticks - like this:


Thanks :slight_smile:

Updated! Cheers for letting me know.

1 Like

Have you published the other users?

By default, Meteor only publishes the current client user to any given client.

Nope. How do I go on about doing that?

Check the Meteor Guide.