aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/styles/prosilver/template/memberlist_im.html
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2007-09-22 18:31:50 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2007-09-22 18:31:50 +0000
commite3882844ec985a62ae573bbcf618c08343afc717 (patch)
treef980f059ded6f06bee2bb3597269209be32cdb3a /phpBB/styles/prosilver/template/memberlist_im.html
parentcbb286420fe5cd82687df99a7f146ffc39408dc7 (diff)
downloadforums-e3882844ec985a62ae573bbcf618c08343afc717.tar
forums-e3882844ec985a62ae573bbcf618c08343afc717.tar.gz
forums-e3882844ec985a62ae573bbcf618c08343afc717.tar.bz2
forums-e3882844ec985a62ae573bbcf618c08343afc717.tar.xz
forums-e3882844ec985a62ae573bbcf618c08343afc717.zip
#i62 - #i65
gone through every javascript invocation and making sure we adhere to our coding guidelines. git-svn-id: file:///svn/phpbb/trunk@8099 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/styles/prosilver/template/memberlist_im.html')
-rw-r--r--phpBB/styles/prosilver/template/memberlist_im.html79
1 files changed, 74 insertions, 5 deletions
diff --git a/phpBB/styles/prosilver/template/memberlist_im.html b/phpBB/styles/prosilver/template/memberlist_im.html
index 43a31e668d..667f68f2c0 100644
--- a/phpBB/styles/prosilver/template/memberlist_im.html
+++ b/phpBB/styles/prosilver/template/memberlist_im.html
@@ -37,8 +37,8 @@
<!-- IF S_SEND_AIM -->
<dl class="fields2">
<dt>&nbsp;</dt>
- <dd><a href="aim:addbuddy?screenname={IM_CONTACT}">{L_IM_ADD_CONTACT}</a></dd>
- <dd><a href="aim:goim?screenname={IM_CONTACT}&amp;message={SITENAME}">{L_IM_SEND_MESSAGE}</a></dd>
+ <dd><a href="{U_AIM_CONTACT}">{L_IM_ADD_CONTACT}</a></dd>
+ <dd><a href="{U_AIM_MESSAGE}">{L_IM_SEND_MESSAGE}</a></dd>
<dd><a href="http://www.aim.com/download.adp">{L_IM_DOWNLOAD_APP}</a> | <a href="http://aimexpress.oscar.aol.com/aimexpress/launch.adp?Brand=AIM">{L_IM_AIM_EXPRESS}</a></dd>
</dl>
<!-- ENDIF -->
@@ -46,9 +46,9 @@
<!-- IF S_SEND_MSNM -->
<dl class="fields2">
<dt>&nbsp;</dt>
- <dd><object classid="clsid:FB7199AB-79BF-11d2-8D94-0000F875C541" codetype="application/x-oleobject" id="objMessengerApp" width="0" height="0"></object></dd>
- <dd><a href="#" onclick="objMessengerApp.LaunchAddContactUI('{IM_CONTACT}'); return false;">{L_IM_ADD_CONTACT}</a></dd>
- <dd><a href="#" onclick="objMessengerApp.LaunchIMUI('{IM_CONTACT}'); return false;">{L_IM_SEND_MESSAGE}</a></dd>
+ <dd><object classid="clsid:B69003B3-C55E-4B48-836C-BC5946FC3B28" codetype="application/x-oleobject" id="objMessengerApp" width="0" height="0"></object></dd>
+ <dd><a href="#" onclick="add_contact('{A_IM_CONTACT}'); return false;">{L_IM_ADD_CONTACT}</a></dd>
+ <dd><a href="#" onclick="im_contact('{A_IM_CONTACT}'); return false;">{L_IM_SEND_MESSAGE}</a></dd>
</dl>
<!-- ENDIF -->
@@ -84,5 +84,74 @@
</form>
+<script type="text/javascript">
+// <![CDATA[
+
+ /** The following will not work with Windows Vista **/
+
+ var app = document.getElementById('objMessengerApp');
+
+ /**
+ * Check whether the browser supports this and whether MSNM is connected
+ */
+ function msn_supported()
+ {
+ // Does the browser support the MSNM object?
+ if (app.MyStatus)
+ {
+ // Is MSNM connected?
+ if (app.MyStatus == 1)
+ {
+ alert('{LA_IM_MSNM_CONNECT}');
+ return false;
+ }
+ }
+ else
+ {
+ alert('{LA_IM_MSNM_BROWSER}');
+ return false;
+ }
+ return true;
+ }
+
+ /**
+ * Add to your contact list
+ */
+ function add_contact(address)
+ {
+ if (msn_supported())
+ {
+ // Could return an error while MSNM is connecting, don't want that
+ try
+ {
+ app.AddContact(0, address);
+ }
+ catch (e)
+ {
+ return;
+ }
+ }
+}
+
+/**
+* Write IM to contact
+*/
+function im_contact(address)
+{
+ if (msn_supported())
+ {
+ // Could return an error while MSNM is connecting, don't want that
+ try
+ {
+ app.InstantMessage(address);
+ }
+ catch (e)
+ {
+ return;
+ }
+ }
+}
+// ]]>
+</script>
<!-- INCLUDE simple_footer.html --> \ No newline at end of file