JediSJ
03-07-2003, 03:52 AM
Note: I've highlighted the relevant sections of the code in yellow.
I made a small modification to the default AIM template so that it would work more smoothly. The original code listed below is straight from vB - it uses javascript to bring up an AIM window and you can message people from that window.
<a href="javascript:aimwindow('$userinfo[aim]')">
<img src="https://vborg.vbsupport.ru/images/aim_icon.gif"
alt="Send an AIM message to $userinfo[username]" border="0"></a>
I found out that you can use straight HTML to launch an AIM window and changed the code to the following:
<a href="aim:goim?screenname=$userinfo[aim]&message=Hello+Are+you+there?">
<img src="https://vborg.vbsupport.ru/images/aim_icon.gif"
alt="Send an AIM message to $userinfo[username]" border="0"></a>
The problem that I'm having only affects users who's screen names have spaces in them. When the link is clicked, it pops up a message box correctly, but the only the first word of the screen name is present. For example, my screen name is Jedi SchattenJgr - when the link is clicked, it pops up a message box to Jedi.
Anyone know of a way to fix this?
EDIT: I know how to fix this in straight HTML (you just add a '+' where the space is) but since vB uses $userinfo[aim] I don't know how to incorperate the +
I made a small modification to the default AIM template so that it would work more smoothly. The original code listed below is straight from vB - it uses javascript to bring up an AIM window and you can message people from that window.
<a href="javascript:aimwindow('$userinfo[aim]')">
<img src="https://vborg.vbsupport.ru/images/aim_icon.gif"
alt="Send an AIM message to $userinfo[username]" border="0"></a>
I found out that you can use straight HTML to launch an AIM window and changed the code to the following:
<a href="aim:goim?screenname=$userinfo[aim]&message=Hello+Are+you+there?">
<img src="https://vborg.vbsupport.ru/images/aim_icon.gif"
alt="Send an AIM message to $userinfo[username]" border="0"></a>
The problem that I'm having only affects users who's screen names have spaces in them. When the link is clicked, it pops up a message box correctly, but the only the first word of the screen name is present. For example, my screen name is Jedi SchattenJgr - when the link is clicked, it pops up a message box to Jedi.
Anyone know of a way to fix this?
EDIT: I know how to fix this in straight HTML (you just add a '+' where the space is) but since vB uses $userinfo[aim] I don't know how to incorperate the +