Sign Up! Login: Password: New User? Forgot? Support
Code 
 
 
Forums 
Forums : Contact > Custom Officer List
Mottie (SuperAdmin) 1/20/2010 6:21 AM EST : Custom Officer List
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

Custom Officer List

GuildPortal admin site link to original post

Well there isn't an easy way to add a list of officers and have their names link to their profile (to allow for messaging, chatting or viewing other pages/info), but I threw together a little script to make it a tiny bit easier.

Basically, follow these steps:
  1. For each officer you will need to get their profile ID#

    • Click on their name in the forums to open their profile. The window should look something like this:


    • See the text at the bottom of the window "/UserClick.aspx?p=537964690&Requestor=GuildPortal"? You will need to copy that ID number in red. As you can see my profile ID is 537964690. I know it's a pain.

    • Alternatively if they've never posted in the forums, you can get their ID from the Control Panel - This actually might be an easier way to do it.

      Go to Control Panel > Member Management > Profile Tracking. Find the person's name and right click on it, then copy the link location. It should be something like this:

      http://guildportal.com/CExplorer/exProfileTracking.aspx?Group=258012&Profile=537964690

      See the profile ID on the end? Paste the link then just copy/cut the ID from there.

  2. Now you just need to add some HTML to a Free Form Text/HTML widget, like this to your Officer List widget. Add it to a list (ul li) or how ever you want, just keep the link HTML like you see it. Replace the profile ID (in red) and User Names (in green).
    <a class="profile tooltip" title="Open profile for Mottie" name="537964690">Mottie</a><br>
    <a class="profile tooltip" title="Open profile for Someone Else" name="111111111">Someone Else</a><br>
    <a class="profile tooltip" title="Open profile for Somebody" name="222222222">Somebody</a><br>
  3. Then add this code inside the widget to make it all work properly.
    <script type="text/javascript">
    $(document).ready(function(){
     $('.profile').click(function(){
      var uid = this.name;
      if (uid == '' || typeof(uid)=="undefined") return false;
      openExternalDialog('/UserClick.aspx?p=' + uid , 515, 605);
      return false;
     })
    })
    </script>
Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

 
 
Key 
New posts No new posts
New posts ( popular ) No new posts ( popular )
New posts ( sticky ) No new posts ( sticky )
New posts ( locked ) No new posts ( locked )
 
 
Who's Online 
There are   members online.
 
 
So-and-so has logged on!
%title%
%message%