vForums Support :: Programming & Coding :: Code Requests & Support :: Expand / Collapse Profile Options - View Topic (Page 2 of 2)
| |
| dog199200 Guest | Re: Expand / Collapse Profile Options (26th Apr 09 at 11:06pm UTC) | | Dregond Rahl's might work, but I'm not for sure, but here is my code: Mini-Profile Template Fragment:
Code: - <table width=130 id="border" class="border" cellpadding="1" cellspacing="1" border=0>
- <tbody>
- <tr>
- <th onclick="moo(this);" align="center" class="title1">*DATE AREA'S NAME HERE*</th>
- </tr>
- <tr class='mp_hide'>
- <td class="window1">
- {additional_info}
- </td>
- </tr>
- </tbody>
- </table>
-
With the part above, just find where it says "{additional_info}" in your Mini-Profile Template and replace it with the code above. Global Footer Code Fragment:
Code: - <style>
- .mp_hide {
- display:none;
- }
- </style>
- <script>
- function moo(s){
- if(s.parentNode.nextSibling.className == 'mp_show'){
- s.parentNode.nextSibling.className = 'mp_hide' } else { s.parentNode.nextSibling.className = 'mp_show';
- }
- }
- </script>
And then to add the toggle effect, just copy the javascript fragment right above this and paste it anywhere within your global footer. | |
| Jedi Slayer Junior Member
Sith Lord Posts: 92 Status: Offline Joined:
pmwwwyahoo | Re: Expand / Collapse Profile Options (27th Apr 09 at 5:01pm UTC) | | so I do not know if i did this right because it does not seem to be working, I put the code in my footer as is, deleted the additional profile option and added the code. T This is what my mini profile looks like now Edit: I thought I might have misunderstood and was suppose to delete everything after additional profile options, but that did not work either.
Code: - <font size="2">
- <center>
- {display_name}
- <br />
- {rank}
- {if:warning}<br />{warning}{/if:warning}
- {if:custom_title}<br />{custom_title}<br />{/if:custom_title}
- </center>
- {if:avatar}<center><br />{avatar}</center>{/if:avatar}
- {if:personal_text}<center><br />{personal_text}</center>{/if:personal_text}
- <br />
- Posts: {posts}
- <br />
- {if:online}
- Status: <b>Online</b>
- {/if:online}
- {ifnot:online}
- Status: Offline
- {/ifnot:online}
- {if:gender}<br />Gender: {gender}{/if:gender}
- {if:location}<br />Location: {location}{/if:location}
- <br />
- Joined: {joined}
- <br />
- {if:contact}
- <br /><center>{contact}</center>
- {/if:contact}
- <table width=130 id="border" class="border" cellpadding="1" cellspacing="1" border=0>
- <tbody>
- <tr>
- <th onclick="moo(this);" align="center" class="title1">My Character Stats</th>
- </tr>
- <tr class='mp_hide'>
- <td class="window1">
- {additional_info}
- </td>
- </tr>
- </tbody>
- </table>
- <br />
- <table cellpadding="0" cellspacing="0">
- <tr>
- <td colspan="2"><font size="2">Reputation: {reputation} </font></td>
- </tr>
- <tr>
- <td rowspan="2">
- <div style="clear: both;">
- {foreach:reputation}
- <div style="height: 8px; width: 8px; background-color: #009900; float: left; margin: 3px;"></div>
- {/foreach:reputation}
- {foreach:negative_reputation}
- <div style="height: 8px; width: 8px; background-color: #CC0000; float: left; margin: 3px;"></div>
- {/foreach:negative_reputation}
- <br style="clear: both;">
- </div>
- </td>
- <td align="center"><font size="1">{reputation_give}</font></td>
- </tr>
- <tr>
- <td align="center"><font size="1">{reputation_take}</font></td>
- </tr>
- </table>
- </font>
-
http://swlounge.virtualforums.co.uk/action/view_profile/user/admin | |
| dog199200 Guest | Re: Expand / Collapse Profile Options (28th Apr 09 at 1:58am UTC) | | well it seems to be working to me, but i also dont got a clue what it looke dliek before, but the dropdown works, just click the rpg stats image and it works | |
| |
| |
|