Categories > TinyButStrong general >

Need help with a memberlist

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: martijn
Date: 2006-10-26
Time: 10:50

Need help with a memberlist

Hi all,

Well, I'm currently programming the administration section of my CMS, and I want to make a memberslist that can display info on all members.

When you open the page, first a list of userids and the usernames is shown, and when you click on a username, a JavaScript toggle function should trigger a div element containing additional information like website adress and display it beneath the username.

However, I seem to have run into problems when generating the html code.
I can't find W3C valid coding to generate the extra info box, either the list of usernames would not be generated correctly, or the extra information divs aren't generated.

This is how it should look like:

1. memberone username
[memberones' extra info, by default hidden but toggled by clicking the username]

2. membertwo username
[same as memberone but for membertwo]

The HTML code I have now is:
                <div>
                    <ul>
                        <li>[members.id;]. <a href="javascript:toggleLayer('memId-[members.id;magnet=div]');">[members.username]</a></li>
                    </ul>
                </div>
               
                    <div id="memId-[members.id]" style="display:none;">
                        <hr/>
                            <ul>
                                <li>Email: [members.email]</li>
                                <li>Website: [members.website]</li>
                                <li>Real name: [members.realname]</li>
                            </ul>
                    </div>

Any help is greatly apreciated.
Thanks in advance!

martijn
By: martijn
Date: 2006-10-26
Time: 11:23

Re: Need help with a memberlist

I've allready solved it :)
<li>[members.id;]. <a href="javascript:toggleLayer('memId-[members.id;block=(div)+div]');">
[members.username]</a></li>
That did the trick :)
Sorry that I've bothered you guys