Discuz!官方免费开源建站系统

 找回密码
 立即注册
搜索

[展示] WEBIM让您的UC Home拥有校内网、Facebook一样的WEBIM!(免费,开源)

[复制链接]
yvsm 发表于 2009-2-13 20:13:59 | 显示全部楼层 |阅读模式
本帖最后由 yvsm 于 2009-4-14 10:57 编辑

WEBIM让您的UC Home拥有校内网、Facebook一样的WEBIM!(已去除错误提示!)

(本人可代为安装,收费2元!)

什么是WEBIM?

下载地址:http://all.58blog.net/down/Code/PHP/2009/0216/580.html

WEBIM是为UCenter Home专门开发的WEB即时通信系统,可以让UC Home拥有搜狐小纸条、校内网、Facebook一样WEBIM。

新版演示地址

http://www.58blog.net

新版功能特点

WEBIM与搜狐小纸条、校内通、Facebook IM的功能类似,实现UC Home好友间的在线聊天;WEBIM新版主要拓展了WEBIM服务器容量,实现100万并发用户支持。

安装步骤:
1.       修改config_im.php的参数设置:

// MySQL Database Configuration

$sql_user   = 'admin';              //数据库用户
$sql_pass   = '58blog.net';              //数据库密码
$sql_host   = 'localhost';            
$sql_db     = '58blog';                 //数据库



// This is the prefix for the ajax im MySQL tables -- this can usually be left alone.

// (If upgrading from a version < 3.1, set the prefix to '')



define('UC_PREFIX', 'uc_');           //uc的前缀

define('SQL_PREFIX', 'uchome_');      //uchome的前缀
$maxBuddyIconSize = 1000;


3.上传程序到根目录
在浏览器中打开以下网址安装数据表

/install.php 安装完后请删除此文件!

4. 打开 /template/default/header.htm 加入红色的部份

找到<script language="javascript" type="text/javascript" src="source/script_face.js"></script>后面添加:
  1. <script src="/js/prototype.js" type="text/javascript"></script>

  2. <script src="/js/effects.js" type="text/javascript"></script>

  3. <script src="/js/window.js" type="text/javascript"></script>

  4. <script src="/js/sm2.js" type="text/javascript"></script>

  5. <script src="/js/utils.js" type="text/javascript"></script>

  6. <script src="/js/config.js" type="text/javascript"></script>

  7. <script src="/js/im.basic.js" type="text/javascript"></script>

  8. <script src="/js/ajax_im.js" type="text/javascript"></script>

  9. <script >

  10. function isgoodok(){return true;}

  11. window.onerror=isgoodok;

  12. </script>
复制代码
在导航的地方插入:
  1. <a href="#"  onclick="javascript:System.login('$_SGLOBAL[supe_username]','qwe');">IM 聊天</a>
复制代码
5. 打开 /template/default/footer.htm 加入红色的部份

   在</body>前面加入:
  1.    <div align="left">

  2. <div id="modal" style="display:none;" align="left">

  3.    <div id="loginDialog" style="display:none;" align="left">

  4.      <p style="display:none;"><span id="login_error_msg" class="dialog_error" style="display:none">&nbsp;</span></p>

  5.      <p style="display:none;" > <span class="dialog_input"><input type="text" id="username"  style="display:block" /></span></p>

  6.       <div style="clear:both"></div>

  7.       <p style="display:none;" ><span class="dialog_label lang-password langinsert-pre">:</span> <span class="dialog_input"><input type="password" id="password" onfoucs="this.select();" onkeypress="System.keyHandler(event, System.login);" /></span></p>

  8.       <div style="clear:both;display:none;"></div>

  9.       <p style="display:none;" >

  10.          <span id="login_dialog_links" class="dialog_links" style="width:285px;" onselectstart="return false;" onmousedown="return false;" style="display:block" >

  11.             <a href="#" class="stdButton lang-signOn" id="signon_button" onclick="System.login();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"></a>

  12.             <a href="#" class="stdButton lang-register registerObject" onclick="Dialogs.register();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"></a>

  13.             <a href="#" class="stdButton lang-forgotPassword langinsert-pre" onclick="Dialogs.forgotPass();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"> </a>

  14.          </span>

  15.       </p>

  16.       <div style="clear:both;display:none;"></div>

  17.    </div>

  18.    <div id="registerDialog" class="registerObject" style="display:none;" align="left">

  19.       <p><span class="dialog_modal_title lang-register"></span></p>

  20.       <div style="clear:both;display:none;"></div>

  21.       <p><span id="register_error_msg" class="dialog_error" style="display:none">&nbsp;</span></p>

  22.       <div style="clear:both;display:none;"></div>

  23.       <p><span class="dialog_label lang-username langinsert-pre">:</span> <span class="dialog_input"><input type="text" id="newusername" onkeypress="System.keyHandler(event, System.register);" /></span></p>

  24.       <div style="clear:both;display:none;"></div>

  25.       <p><span class="dialog_label lang-password langinsert-pre">:</span> <span class="dialog_input"><input type="password" id="newpassword" onkeypress="System.keyHandler(event, System.register);" /></span></p>

  26.       <div style="clear:both;display:none;"></div>

  27.       <p><span class="dialog_label lang-confirm langinsert-pre">:</span> <span class="dialog_input"><input type="password" id="newpassword2" onkeypress="System.keyHandler(event, System.register);" /></span></p>

  28.       <div style="clear:both"style="display:none;"></div>

  29.       <p><span class="dialog_label lang-email langinsert-pre">:</span> <span class="dialog_input"><input type="text" id="newemail" onkeypress="System.keyHandler(event, System.register);" /></span></p>

  30.       <div style="clear:both;display:none;"></div>

  31.       <p>

  32.          <span class="dialog_links" style="width:190px;" onselectstart="return false;" onmousedown="return false;">

  33.             <a href="#" class="stdButton lang-register" id="register_button" onclick="System.register();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"></a>

  34.             <a href="#" class="stdButton lang-cancel" onclick="Dialogs.login();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"></a>

  35.          </span>

  36.       </p>

  37.       <div style="clear:both;display:none;"></div>

  38.    </div>

  39.    

  40.    <div id="forgotPassDialog" style="display:none;" align="left">

  41.       <p><span class="dialog_modal_title lang-passwordReset"></span></p>

  42.       <div style="clear:both;display:none;"></div>

  43.       <p><span id="forgotpass_error_msg" class="dialog_error" style="display:none">&nbsp;</span></p>

  44.       <div style="clear:both;display:none;"></div>

  45.       <p><span class="dialog_label lang-emailAddress langinsert-pre">: </span> <span class="dialog_input"><input type="text" id="resetto" onkeypress="System.keyHandler(event, System.resetPass);" /></span></p>

  46.       <div style="clear:both;display:none;"></div>

  47.       <p>

  48.          <span class="dialog_links" style="width:190px;" onselectstart="return false;" onmousedown="return false;" style="display:none;">

  49.             <a href="#" class="stdButton lang-reset" id="forgotpass_button" onclick="System.resetPass();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"></a>

  50.             <a href="#" class="stdButton lang-cancel" onclick="Dialogs.login();return false;" onmouseover="ButtonCtl.hover(this);" onmousedown="ButtonCtl.down(this);" onmouseup="ButtonCtl.normal(this);" onmouseout="ButtonCtl.normal(this);"></a>

  51.          </span>

  52.       </p>

  53.       <div style="clear:both;display:none;"></div>

  54.    </div>

  55. </div>

  56. <div class="itemList" id="statusList" style="display:none;" align="left">

  57.    <a href="#" class="lang-available langinsert-post" onclick="Status.set(0, Languages.get('available'));return false;"><img src="/themes/dark/online.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  58.    <a href="#" class="lang-friendsOnly langinsert-post" style="border-bottom: 1px solid #bfbcb8;" onclick="Status.set(99, Languages.get('friendsOnly'));return false;"><img src="/themes/dark/online.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  59.    <a href="#" class="lang-busy langinsert-post" onclick="Status.set(1, Languages.get('busy'));return false;"><img src="/themes/dark/away.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  60.    <a href="#" class="lang-beBackLater langinsert-post" onclick="Status.set(1, Languages.get('beBackLater'));return false;"><img src="/themes/dark/away.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  61.    <a href="#" class="lang-away langinsert-post" onclick="Status.set(1, Languages.get('away'));return false;"><img src="/themes/dark/away.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  62.    <a href="#" class="lang-custom langinsert-post" id="customMessage" style="border-top: 1px solid #bfbcb8;" onclick="Status.customAway();$('statusList').style.display='none';return false;"><img src="/themes/dark/away.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  63.    <a href="#" class="lang-invisible langinsert-post" style="border-top: 1px solid #bfbcb8;" onclick="Status.set(49, Languages.get('invisible'));return false;"><img src="/themes/dark/offline.png" style="border:0;" alt="" title="" />&nbsp;&nbsp;</a>

  64. </div>

  65. <div class="itemList" id="fontsList" style="display:none;" align="left">

  66.    <a href="#" onclick="IM.active.setFont('宋体');return false;">宋体</a>

  67.    <a href="#" onclick="IM.active.setFont('楷体');return false;">楷体</a>

  68.    <a href="#" onclick="IM.active.setFont('隶书');return false;">隶书</a>   

  69.    <a href="#" onclick="IM.active.setFont('黑体');return false;">黑体</a>

  70.    <a href="#" onclick="IM.active.setFont('Arial');return false;">Arial</a>

  71.    <a href="#" onclick="IM.active.setFont('Comic Sans MS');return false;">Comic Sans MS</a>

  72.    <a href="#" onclick="IM.active.setFont('Courier New');return false;">Courier New</a>

  73.    <a href="#" onclick="IM.active.setFont('Garamond');return false;">Garamond</a>

  74.    <a href="#" onclick="IM.active.setFont('Georgia');return false;">Georgia</a>

  75.    <a href="#" onclick="IM.active.setFont('Impact');return false;">Impact</a>

  76.    <a href="#" onclick="IM.active.setFont('Tahoma');return false;">Tahoma</a>

  77.    <a href="#" onclick="IM.active.setFont('Times New Roman');return false;">Times New Roman</a>

  78.    <a href="#" onclick="IM.active.setFont('Verdana');return false;">Verdana</a>

  79. </div>

  80. <div class="itemList" id="fontSizeList" oncontextmenu="return false;" style="display:none;" align="left">

  81.    <a href="#" onclick="IM.active.setFontSize(8);return false;">8</a>

  82.    <a href="#" onclick="IM.active.setFontSize(10);return false;">10</a>

  83.    <a href="#" onclick="IM.active.setFontSize(12);return false;">12</a>

  84.    <a href="#" onclick="IM.active.setFontSize(14);return false;">14</a>

  85.    <a href="#" onclick="IM.active.setFontSize(16);return false;">16</a>

  86.    <a href="#" onclick="IM.active.setFontSize(18);return false;">18</a>

  87.    <a href="#" onclick="IM.active.setFontSize(20);return false;">20</a>

  88.    <a href="#" onclick="IM.active.setFontSize(22);return false;">22</a>

  89.    <a href="#" onclick="IM.active.setFontSize(24);return false;">24</a>

  90. </div>

  91. <div class="itemList" id="fontColorList" style="cursor: pointer;display:none;" align="left">

  92.    <table class="tTable">

  93.       <tr>

  94.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#000000;" onclick="IM.active.setFontColor('#000000');"></td>

  95.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#b8b8b8;" onclick="IM.active.setFontColor('#b8b8b8');"></td>

  96.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#b4ad3b;" onclick="IM.active.setFontColor('#b4ad3b');"></td>

  97.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#bb5c54;" onclick="IM.active.setFontColor('#bb5c54');"></td>

  98.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#755a5c;" onclick="IM.active.setFontColor('#755a5c');"></td>

  99.       </tr>

  100.       <tr>

  101.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#a9b5ef;" onclick="IM.active.setFontColor('#a9b5ef');"></td>

  102.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#d65a20;" onclick="IM.active.setFontColor('#d65a20');"></td>

  103.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#e39230;" onclick="IM.active.setFontColor('#e39230');"></td>

  104.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#a71334;" onclick="IM.active.setFontColor('#a71334');"></td>

  105.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#590099;" onclick="IM.active.setFontColor('#590099');"></td>

  106.       </tr>

  107.       <tr>

  108.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#d40088;" onclick="IM.active.setFontColor('#d40088');"></td>

  109.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#0030ac;" onclick="IM.active.setFontColor('#0030ac');"></td>

  110.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#676f11;" onclick="IM.active.setFontColor('#676f11');"></td>

  111.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#769321;" onclick="IM.active.setFontColor('#769321');"></td>

  112.          <td class="colorItem" style="width:13px;height:13px;border:1px solid #000;background-color:#3966fe;" onclick="IM.active.setFontColor('#3966fe');"></td>

  113.       </tr>

  114.    </table>

  115. </div>

  116. <div class="itemList" id="divContext" oncontextmenu="return false;" style="display:none;" align="left">

  117.    <a href="#" class="lang-contextGetInfo" onclick="Context.profile();return false;"></a>

  118.    <a href="#" class="lang-contextIM" onclick="Context.createIM();return false;"></a>

  119.    <a href="#" id="contextBlock" class="lang-contextBlock" onclick="Context.blockBuddy();return false;"></a>

  120.    <a href="#" class="lang-contextRemove" onclick="Context.removeBuddy();return false;"></a>

  121. </div>

  122. <div id="languageList" style="display:none;" align="left">

  123. </div>

  124. </div>
复制代码
如有问题,请联系:www.58blog.net

不好意思,论坛限制了上传大小,我这边没法分卷所以就上传到自己的论坛了
http://bbs.58blog.net/viewthread.php?tid=504&extra=
image002.jpg
image003.png
回复

使用道具 举报

 楼主| yvsm 发表于 2009-2-13 20:15:18 | 显示全部楼层
本帖最后由 yvsm 于 2009-2-16 18:55 编辑

QQ截图未命名.jpg
如果出错,请自己执行SQL:
  1. ALTER TABLE `uchome_member` ADD `email` text;
  2. ALTER TABLE `uchome_member` ADD `is_online` int(11) default 0;
  3. ALTER TABLE `uchome_member` ADD `last_ping` text;
  4. ALTER TABLE `uchome_member` ADD `last_ip` varchar(15) default NULL;
  5. ALTER TABLE `uchome_member` ADD `banned` tinyint(1) default 0;
  6. ALTER TABLE `uchome_member` ADD `admin` tinyint(1) default 0;
  7. ALTER TABLE `uchome_member` ADD `buddyicon` varchar(4) default 'none';
  8. ALTER TABLE `uchome_member` ADD `profile` text

  9. UPDATE `uchome_member` set admin=1 where username='这里是你管理员的帐户'
复制代码
uchome_是你的前缀;这里是你管理员的帐户 这里填你的帐户;

把上面的代码在数据库执行sql。就可以
回复

使用道具 举报

435479 发表于 2009-2-13 20:15:27 | 显示全部楼层
~~~~~~~~~~~~~~~~~~~~~~~!
回复

使用道具 举报

435479 发表于 2009-2-13 20:18:29 | 显示全部楼层
呵呵~~~分享吗?
回复

使用道具 举报

zgdxs 发表于 2009-2-13 20:23:26 | 显示全部楼层
下载地址呢?

((em:01))
回复

使用道具 举报

qhdyezhu 发表于 2009-2-13 20:42:16 | 显示全部楼层
没人用啊
回复

使用道具 举报

xieyouyuan 发表于 2009-2-13 21:10:07 | 显示全部楼层
分享吧 我等你好久了  你终于更新了
回复

使用道具 举报

xieyouyuan 发表于 2009-2-13 21:31:43 | 显示全部楼层
错误: 未知错误
回复

使用道具 举报

it2500 发表于 2009-2-13 22:24:01 | 显示全部楼层
这是收费软件,等降价,现在稍显贵了些,草根站长有点承受不了
回复

使用道具 举报

nilo 发表于 2009-2-13 22:51:13 | 显示全部楼层
ajax im???
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2025-9-13 05:16 , Processed in 0.142918 second(s), 17 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表