06-19-2000, 09:27 AM
Error with the last instructions. You'll want to edit 2 templates.
I was bored so I decided to add in some javascript to allow users to view the avatar before they select. You only need to edit the registeradult and modifyprofile templates.
So log into the control panel and select to edit the template. Find $cssinclude, and under it add:
<script language="javascript">
function showavatar()
{
if (!document.images)
return
document.images.pictures.src=
document.preferences.avatar.options[document.preferences.avatar.selectedIndex].value
}
</script>
Now find <select name="avatar" size="4"> and replace it with <select name="avatar" size="4" onChange="showavatar()">. Then a few lines down, underneat </select>, add <img src="images/avatars/blank.gif" name="pictures">.
I'd recommend having the initial image being a small box that says Select Avatar or something simple like that.
Thats it.
Working example: http://4.3.235.30/forums/member.php?action=register&who=adult
[Edited by Krucifyx on 06-20-2000 at 06:35 PM]
I was bored so I decided to add in some javascript to allow users to view the avatar before they select. You only need to edit the registeradult and modifyprofile templates.
So log into the control panel and select to edit the template. Find $cssinclude, and under it add:
<script language="javascript">
function showavatar()
{
if (!document.images)
return
document.images.pictures.src=
document.preferences.avatar.options[document.preferences.avatar.selectedIndex].value
}
</script>
Now find <select name="avatar" size="4"> and replace it with <select name="avatar" size="4" onChange="showavatar()">. Then a few lines down, underneat </select>, add <img src="images/avatars/blank.gif" name="pictures">.
I'd recommend having the initial image being a small box that says Select Avatar or something simple like that.
Thats it.
Working example: http://4.3.235.30/forums/member.php?action=register&who=adult
[Edited by Krucifyx on 06-20-2000 at 06:35 PM]