mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-29 14:48:53 +00:00
MSNM should work again (as before, only on IE). git-svn-id: file:///svn/phpbb/trunk@6531 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
0b838cec29
commit
7058666615
3 changed files with 74 additions and 7 deletions
|
@ -72,6 +72,8 @@ $lang = array_merge($lang, array(
|
||||||
'IM_JABBER_SUBJECT' => 'This is an automated message please do not reply! Message from user %1$s at %2$s',
|
'IM_JABBER_SUBJECT' => 'This is an automated message please do not reply! Message from user %1$s at %2$s',
|
||||||
'IM_MESSAGE' => 'Your message',
|
'IM_MESSAGE' => 'Your message',
|
||||||
'IM_MSNM' => 'Please note that you need Windows Messenger installed to use this.',
|
'IM_MSNM' => 'Please note that you need Windows Messenger installed to use this.',
|
||||||
|
'IM_MSNM_BROWSER' => 'Your browser does not support this.',
|
||||||
|
'IM_MSNM_CONNECT' => 'MSNM is not connected.\nYou have to connect to MSNM to continue.',
|
||||||
'IM_NAME' => 'Your Name',
|
'IM_NAME' => 'Your Name',
|
||||||
'IM_NO_JABBER' => 'Sorry, direct messaging of Jabber users is not supported on this server. You will need a Jabber client installed on your system to contact the recipient above.',
|
'IM_NO_JABBER' => 'Sorry, direct messaging of Jabber users is not supported on this server. You will need a Jabber client installed on your system to contact the recipient above.',
|
||||||
'IM_RECIPIENT' => 'Recipient',
|
'IM_RECIPIENT' => 'Recipient',
|
||||||
|
|
|
@ -28,7 +28,77 @@
|
||||||
|
|
||||||
<!-- IF S_SEND_MSNM -->
|
<!-- IF S_SEND_MSNM -->
|
||||||
<tr>
|
<tr>
|
||||||
<td class="row1" colspan="2" align="center"><object classid="clsid:FB7199AB-79BF-11d2-8D94-0000F875C541" codetype="application/x-oleobject" id="objMessengerApp" width="0" height="0"></object><br /><a class="gen" href="#" onclick="objMessengerApp.LaunchAddContactUI('{IM_CONTACT}'); return false;">{L_IM_ADD_CONTACT}</a><br /><a class="gen" href="#" onclick="objMessengerApp.LaunchIMUI('{IM_CONTACT}'); return false;">{L_IM_SEND_MESSAGE}</a></td>
|
<td class="row1" colspan="2" align="center">
|
||||||
|
<object classid="clsid:B69003B3-C55E-4B48-836C-BC5946FC3B28" codetype="application/x-oleobject" id="objMessengerApp" width="0" height="0"></object>
|
||||||
|
<script language="javascript" type="text/javascript">
|
||||||
|
<!--
|
||||||
|
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('{L_IM_MSNM_CONNECT}');
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
alert('{L_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>
|
||||||
|
|
||||||
|
<a class="gen" href="#" onclick="add_contact('{IM_CONTACT}'); return false;">{L_IM_ADD_CONTACT}</a><br /><a class="gen" href="#" onclick="im_contact('{IM_CONTACT}'); return false;">{L_IM_SEND_MESSAGE}</a>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="cat" colspan="2" align="center"> </td>
|
<td class="cat" colspan="2" align="center"> </td>
|
||||||
|
|
|
@ -14,12 +14,7 @@
|
||||||
{META}
|
{META}
|
||||||
<title>{SITENAME} • {PAGE_TITLE}</title>
|
<title>{SITENAME} • {PAGE_TITLE}</title>
|
||||||
|
|
||||||
<link rel="stylesheet" href="{T_STYLESHEET_LINK}" type="text/css">
|
<link rel="stylesheet" href="{T_STYLESHEET_LINK}" type="text/css" />
|
||||||
<style type="text/css">
|
|
||||||
<!--
|
|
||||||
{T_STYLESHEET_DATA}
|
|
||||||
//-->
|
|
||||||
</style>
|
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|
Loading…
Add table
Reference in a new issue