Skins

How can I generate the link to the "member details" page?

Scenario:
"I would like to add the link to my "Main Index" but there is no way I'm able to find the name of the tag displaying such a url!"

Solution:
Put the following code in your skin somewhere:

<%if(loggedin)%>
  <a href="index.php?memberid=<%member(yourid)%>">Your profile</a>
<%endif%>

Original forum thread:
http://forum.nucleuscms.org/viewtopic.php?t=11078

Walkthrough:
In this example, we are going to put our profile link in the sidebar of the default skin, just underneath the admin area link that is visible when the user is logged in.

  1. Go into your Nucleus admin area and click on "Skin Files".
    Click on "Skin Files"
  2. Click on the "default" folder to edit the default skin files.
    Click on the "default" folder to edit the default skin files
  3. Since we want to put the link to the member page in the sidebar, we'll need to edit sidebar.inc by clicking on its "Edit" link.
    Click on the "Edit" link next to sidebar.inc to edit the file
  4. Now, scroll down until you see this code:
    <!-- admin link, only visible if logged in -->
    <%if(loggedin)%>
    <dd><a href="<%adminurl%>" title="Admin Area">Admin</a></dd>
    <%endif%>
    </dl>
    </div>

    Place the following code in a new line before the <%endif%>:

    <dd><a href="index.php?memberid=<%member(yourid)%>" title="<%member(yourname)%>'s Profile"><%member(yourname)%>'s Profile</a></dd>

    Insert the above code into your sidebar.inc file
  5. And now you're done!
    See your new profile link in action!
section: Skins | submitted by Leng on 2006.Feb.18 | 3336 views

item rate
Total votes: 4 - Rating: 9.50

Please tell us how useful this answer was to you (0 = useless, 10 = very very helpful):

10