Como adicionar opções moderativas no Chatbox?
+2
[K]oke
Uatyla
6 participantes
Fórum dos Fóruns :: Ajuda e atendimento ao utilizador :: Questões sobre códigos :: Questões resolvidas sobre códigos Javascript e jQuery
Página 1 de 1
Como adicionar opções moderativas no Chatbox?
Detalhes da dúvida
Versão do fórum : phpBB3Nível de acesso : Fundador
Navegador usado : Mozilla Firefox, Google Chrome, Opera
Membros afetados : Todos os membros do fórum
Problema começou : a +/- 10 dias
Endereço do fórum : http://vidadeaquarista.forumeiros.com/forum
Descrição do problema
Olá caros colegas!A +/- uns 10 dias nosso chat box bugou e não aparece nada nele, e também não é possível digitar nada.
Vendo o fórum de um colega aqui do FDF vi esse chatbox http://www.forumpublicando.com/ e fiquei interessado, e gostaria de saber como adiciona-lo ao meu fórum?
Última edição por Uatyla em 06.01.15 18:46, editado 1 vez(es)
Re: Como adicionar opções moderativas no Chatbox?
Boa tarde!
Poderia nos informar uma imagem do que precisa?
Até mais!
Poderia nos informar uma imagem do que precisa?
Até mais!
Re: Como adicionar opções moderativas no Chatbox?
Ok aqui está a imagem do meu chat!
Desejo que ele funcione, semelhante a esse, pois o meu bugou e não funciona!
Desejo que ele funcione, semelhante a esse, pois o meu bugou e não funciona!
Re: Como adicionar opções moderativas no Chatbox?
UP!
Para facilitar o entendimento os código que uso são esses...
J.S
HTML
[code:1:c6c4] <!--
// Copyright? (c) 2013 JScript <jscriptbrasil at live.com>
// This work is free. You can redistribute it and/or modify it
// under the terms of the WTFPL, Version 2
// Based on IPBoard ShoutBox, all rights reserved!
--> <title>Chatbox</title> <meta content="text/html; charset=utf-8" http-equiv="content-type" /> <meta content="text/javascript" http-equiv="content-script-type" /> <meta content="text/css" http-equiv="content-style-type" /> <link href="http://illiweb.com/fa/favicon/write.ico" type="image/x-icon" rel="shortcut icon" /> <link type="text/css" href="https://googledrive.com/host/0BywKunb3ieyDdVlWcUlScmk2SlE/ShoutBox.css" rel="stylesheet" /> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> <script type="text/javascript" src="https://googledrive.com/host/0BywKunb3ieyDdVlWcUlScmk2SlE/lz-string-1.3.0-rc1.js"></script> <script type="text/javascript" src="https://googledrive.com/host/0BywKunb3ieyDaW5OTFJCWl95VzA/ShoutBox.js" charset="ISO-8859-1"></script> <script type="text/javascript">
//<![CDATA[
var params = '?archives=1';
var smilies_sid = '';
var url_chat = '/chatbox/index.forum';
//]]>
</script> <style type="text/css">
* {margin: 0;padding: 0;}
html, body {overflow: hidden;}
body {padding: 0;margin: 0;background-color: #fbfbfb; font-family: helvetica,arial,sans-serif !important}
.fontbutton {border:0;}
</style>
<div id="ajax_loading" style="display: none;">
<img alt="Carregando..." src="http://i69.servimg.com/u/f69/18/17/62/92/ajax_l10.gif" />
</div>
<div id="shoutbox-temp-msgs" style="display: none;">
</div>
<div id="shoutbox-temp-imgs" style="display: none;">
</div>
<div id="category_shoutbox" class="category_block block_wrap" style="min-height: 300px; min-width: 720px; width: 100%;">
<h3 class="maintitle">
<a title="Fechar/Abrir shoutbox" href="#" class="toggle right">Fechar/Abrir shoutbox</a> <a title="View Main Shoutbox" href="#" target="_top">IPBoard Chat (v1.1112pr) </a>
</h3>
<div class="ipsBox table_wrap">
<div class="ipsBox_container">
<table class="ipb_table shoutbox_table" style="height: 230px; min-height: 230px;">
<tbody>
<tr class="row2" id="shoutbox-announcement-row">
<td colspan="2" class="altrow" valign="middle">
<div class="message" id="shoutbox-announcement-text">
A ofensa a outro membro / Staff é sujeito a punições. <strong class="bbc">O ChatBox é um lugar para descontração, não de ajuda e suporte!</strong>
</div>
</td>
</tr>
<tr class="row1">
<td colspan="2" class="altrow" valign="top">
<div id="shoutbox-shouts" style="overflow: auto; overflow-x: hidden; left: 0px; top: 0px; height: 169px; min-height: 128px;">
<p id="shoutbox-inactive-prompt" style="display: none; height: 126px;" class="altrow short">
<br />Nós percebemos que você esteve inativo por mais de 10 minutos.<br /> O shoutbox parou de ser executado devido a sua inatividade.<br /> Se você está de volta, por favor clique no botão abaixo <span style="text-decoration: underline;">Estou de Volta!</span>. <br /><br /> <input onclick="I_am_back();" class="input_submit" value="Estou de Volta!" type="button" />
</p>
<p id="shoutbox-service" style="display: none; height: 126px;" class="altrow short">
<br /><br />Nosso shoutbox está passando por manutenção neste momento, agradecemos a sua compreênção!<br /> Em breve estaremos funcionando normalmente, grato pela sua visita...<br /> O shoutbox parou de ser executado por motivos técnicos. <br />
</p>
<div id="chatbox_members" style="display: none;" increment="10" pageincrement="144" maxpos="460" curpos="0">
</div>
<table id="shoutbox-shouts-table" style="display: ;">
<tbody id="chatbox_general" class="chat_toggle" style="display: ;" curpos="188" maxpos="325" pageincrement="0" increment="10">
<!-- General ChatBox content -->
</tbody>
<tbody id="chatbox_mpreceive" class="chat_toggle" style="display: none;" curpos="188" maxpos="325" pageincrement="0" increment="10">
<!-- Private Receive Message ChatBox content -->
</tbody>
<tbody id="chatbox_mpsend" class="chat_toggle" style="display: none;" curpos="188" maxpos="325" pageincrement="0" increment="10">
<!-- Private Send Message ChatBox content -->
</tbody>
</table>
</div>
<div id="shouts-global-resizer" title="Clique para redimensionar o ShoutBox!" onmousedown="resizeElement();">
</div>
<div style="display: none;" class="message error block_wrap" id="shoutbox-inline-error-glb">
</div>
</td>
</tr>
<!-- Buttons -->
<tr class="row1">
<td colspan="2" class="altrow" valign="top">
<form onsubmit="submitmsg('?archives=1');return false;" method="post" action="" name="post">
<div id="chatbox_messenger_form" style="display: ">
<div onclick="document.post.message.focus();timer_count=0;">
<input id="message" name="message" size="70" maxlength="1024" class="input_text" autocomplete="off" onkeydown="number_of_refresh=0;timer_count=0;" type="text" /> <input class="input_submit" value="Enviar Shout" id="submit_button" name="submit_button" type="submit" /> <input class="input_submit alt" value="Limpar" id="shoutbox-clear-button" onclick="document.getElementById('message').value = '';" type="button" /> <input class="input_submit alt" value="Atualizar" id="shoutbox-refresh-button" style="" onclick="refresh_chatbox('?archives=1');" type="button" /> <input data-scope="shoutbox" onclick="do_selectsmilies(event);" class="input_submit alt" value="Smilies" id="divsmilies" type="button" /> <input class="input_submit alt" value="BBCode" id="shoutbox-bbcode-button" onclick="window.open('/faq?mode=bbcode','BBCodes Help','status=no,location=no,toolbar=no,menubar=no,personalbar=no,width=640,height=window.innerHeight,scrollbars=yes,resizable=yes,left=0,top=0'); return false;" type="button" /> <input class="input_submit alt" value="Preferências" id="shoutbox-myprefs-button" onclick="$('#myPrefs_popup').toggle();" type="button" />
</div>
</div>
</form>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<!-- Smiles -->
<div id="shoutbox-smilies-button_menucontent" style="display: none; width: 400px; position: absolute; z-index: 9999; top: 1px; left: 1px;">
<h3 class="maintitle short">
<span class="pager"><a id="page_0" class="emoticonPager" href="#">«</a> </span> More <span class="pager"> <a id="page_1" class="emoticonPager" href="#">»</a></span>
</h3>
<table class="ipb_table" style="background: none repeat scroll 0 0 #FFFFFF;">
<tbody>
<tr id="smile_row" class="row1">
<td>
<span> <a style="margin-left: 10px;" href="#" onclick="copy_user_name(':sos:')"> <img style="margin-bottom: 10px;" alt="No Like!" src="http://r19.imgfast.net/users/1917/43/09/52/smiles/632187147.gif" title="SOS" /> </a> <a style="margin-left: 10px;" href="#" onclick="copy_user_name(':D')"> <img style="margin-bottom: 10px;" alt="Very Happy" src="http://2img.net/i/fa/i/smiles/icon_biggrin.png" title="Very Happy" /> </a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':)')"><img style="margin-bottom: 10px;" alt="Smile" src="http://2img.net/i/fa/i/smiles/icon_smile.gif" title="Smile" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':(')"><img style="margin-bottom: 10px;" alt="Sad" src="http://2img.net/i/fa/i/smiles/icon_sad.gif" title="Sad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':o')"><img style="margin-bottom: 10px;" alt="Surprised" src="http://2img.net/i/fa/i/smiles/icon_surprised.gif" title="Surprised" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name('<img src=" http:="" illiweb.com="" fa="" i="" smiles="" icon_eek.gif"="" alt="Shocked" longdesc="42">')"><img style="margin-bottom: 10px;" alt="Shocked" src="http://2img.net/i/fa/i/smiles/icon_eek.gif" title="Shocked" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name('8)')"><img style="margin-bottom: 10px;" alt="Cool" src="http://2img.net/i/fa/i/smiles/icon_cool.gif" title="Cool" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':lol:')"><img style="margin-bottom: 10px;" alt="Laughing" src="http://2img.net/i/fa/i/smiles/icon_lol.gif" title="Laughing" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':x')"><img style="margin-bottom: 10px;" alt="Mad" src="http://2img.net/i/fa/i/smiles/icon_mad.gif" title="Mad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':P')"><img style="margin-bottom: 10px;" alt="Razz" src="http://2img.net/i/fa/i/smiles/icon_razz.gif" title="Razz" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':oops:')"><img style="margin-bottom: 10px;" alt="Embarassed" src="http://2img.net/i/fa/i/smiles/icon_redface.gif" title="Embarassed" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cry:')"><img style="margin-bottom: 10px;" alt="Crying or Very sad" src="http://2img.net/i/fa/i/smiles/icon_cry.gif" title="Crying or Very sad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':evil:')"><img style="margin-bottom: 10px;" alt="Evil or Very Mad" src="http://2img.net/i/fa/i/smiles/icon_evil.gif" title="Evil or Very Mad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':twisted:')"><img style="margin-bottom: 10px;" alt="Twisted Evil" src="http://2img.net/i/fa/i/smiles/icon_twisted.gif" title="Twisted Evil" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':roll:')"><img style="margin-bottom: 10px;" alt="Rolling Eyes" src="http://2img.net/i/fa/i/smiles/icon_rolleyes.gif" title="Rolling Eyes" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(';)')"><img style="margin-bottom: 10px;" alt="Wink" src="http://2img.net/i/fa/i/smiles/icon_wink.gif" title="Wink" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':!:')"><img style="margin-bottom: 10px;" alt="Exclamation" src="http://2img.net/i/fa/i/smiles/icon_exclaim.gif" title="Exclamation" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':?:')"><img style="margin-bottom: 10px;" alt="Question" src="http://2img.net/i/fa/i/smiles/icon_question.gif" title="Question" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':idea:')"><img style="margin-bottom: 10px;" alt="Idea" src="http://2img.net/i/fa/i/smiles/icon_idea.png" title="Idea" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':arrow:')"><img style="margin-bottom: 10px;" alt="Arrow" src="http://2img.net/i/fa/i/smiles/icon_arrow.gif" title="Arrow" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':|')"><img style="margin-bottom: 10px;" alt="Neutral" src="http://2img.net/i/fa/i/smiles/icon_neutral.gif" title="Neutral" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':face:')"><img style="margin-bottom: 10px;" alt="What a Face" src="http://2img.net/i/fa/i/smiles/fresse.png" title="What a Face" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':star:')"><img style="margin-bottom: 10px;" alt="Like a Star @ heaven" src="http://2img.net/i/fa/i/smiles/star3.png" title="Like a Star @ heaven" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':suspect:')"><img style="margin-bottom: 10px;" alt="Suspect" src="http://2img.net/i/fa/i/smiles/suspect.gif" title="Suspect" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':heart:')"><img style="margin-bottom: 10px;" alt="I love you" src="http://2img.net/i/fa/i/smiles/herz.png" title="I love you" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':no:')"><img style="margin-bottom: 10px;" alt="No" src="http://2img.net/i/fa/i/smiles/kopfschuettel.gif" title="No" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name('<img src=" users="" 2117="" 37="" 44="" 56="" smiles="" 3350979868.gif"="" alt="Bravo" longdesc="9">')"><img style="margin-bottom: 10px;" alt="@" src="http://2img.net/i/fa/i/smiles/at.png" title="@" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cyclops:')"><img style="margin-bottom: 10px;" alt="cyclops" src="http://2img.net/i/fa/i/smiles/icon_cyclops.gif" title="cyclops" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':clown:')"><img style="margin-bottom: 10px;" alt="clown" src="http://2img.net/i/fa/i/smiles/icon_clown.png" title="clown" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':pirat:')"><img style="margin-bottom: 10px;" alt="pirat" src="http://2img.net/i/fa/i/smiles/icon_pirat.png" title="pirat" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':tongue:')"><img style="margin-bottom: 10px;" alt="tongue" src="http://2img.net/i/fa/i/smiles/icon_tongue.png" title="tongue" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':silent:')"><img style="margin-bottom: 10px;" alt="silent" src="http://2img.net/i/fa/i/smiles/icon_silent.png" title="silent" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':pale:')"><img style="margin-bottom: 10px;" alt="pale" src="http://2img.net/i/fa/i/smiles/icon_pale.gif" title="pale" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':alien:')"><img style="margin-bottom: 10px;" alt="alien" src="http://2img.net/i/fa/i/smiles/alien.png" title="alien" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cat:')"><img style="margin-bottom: 10px;" alt="cat" src="http://2img.net/i/fa/i/smiles/icon_cat.png" title="cat" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':monkey:')"><img style="margin-bottom: 10px;" alt="monkey" src="http://2img.net/i/fa/i/smiles/icon_monkey.png" title="monkey" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':pig:')"><img style="margin-bottom: 10px;" alt="pig" src="http://2img.net/i/fa/i/smiles/icon_porc.png" title="pig" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':rabbit:')"><img style="margin-bottom: 10px;" alt="rabbit" src="http://2img.net/i/fa/i/smiles/icon_rabbit.png" title="rabbit" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':bounce:')"><img style="margin-bottom: 10px;" alt="bounce" src="http://2img.net/i/fa/i/smiles/icon_bounce.gif" title="bounce" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':confused:')"><img style="margin-bottom: 10px;" alt="confused" src="http://2img.net/i/fa/i/smiles/confused.png" title="confused" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':affraid:')"><img style="margin-bottom: 10px;" alt="affraid" src="http://2img.net/i/fa/i/smiles/affraid.gif" title="affraid" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':bball:')"><img style="margin-bottom: 10px;" alt="Basketball" src="http://2img.net/i/fa/i/smiles/icon_basketball.gif" title="Basketball" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cheers:')"><img style="margin-bottom: 10px;" alt="cheers" src="http://2img.net/i/fa/i/smiles/icon_cheers.png" title="cheers" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':bom:')"><img style="margin-bottom: 10px;" alt="bom" src="http://2img.net/i/fa/i/smiles/bom.png" title="bom" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':drunken:')"><img style="margin-bottom: 10px;" alt="drunken" src="http://2img.net/i/fa/i/smiles/drunken_smilie.png" title="drunken" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':sleep:')"><img style="margin-bottom: 10px;" alt="Sleep" src="http://2img.net/i/fa/i/smiles/sleep.gif" title="Sleep" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':sunny:')"><img style="margin-bottom: 10px;" alt="sunny" src="http://2img.net/i/fa/i/smiles/icon_sunny.png" title="sunny" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':albino:')"><img style="margin-bottom: 10px;" alt="albino" src="http://2img.net/i/fa/i/smiles/icon_albino.png" title="albino" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cherry:')"><img style="margin-bottom: 10px;" alt="cherry" src="http://2img.net/i/fa/i/smiles/icon_cherry.png" title="cherry" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':santa:')"><img style="margin-bottom: 10px;" alt="santa" src="http://2img.net/i/fa/i/smiles/icon_santa.png" title="santa" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':rendeer:')"><img style="margin-bottom: 10px;" alt="rendeer" src="http://2img.net/i/fa/i/smiles/icon_rendeer.png" title="rendeer" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':farao:')"><img style="margin-bottom: 10px;" alt="farao" src="http://2img.net/i/fa/i/smiles/icon_farao.png" title="farao" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':king:')"><img style="margin-bottom: 10px;" alt="king" src="http://2img.net/i/fa/i/smiles/icon_king.png" title="king" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':queen:')"><img style="margin-bottom: 10px;" alt="queen" src="http://2img.net/i/fa/i/smiles/icon_queen.png" title="queen" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':joker:')"><img style="margin-bottom: 10px;" alt="jocolor" src="http://2img.net/i/fa/i/smiles/icon_jokercolor.png" title="jocolor" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':geek:')"><img style="margin-bottom: 10px;" alt="geek" src="http://2img.net/i/fa/i/smiles/icon_geek.png" title="geek" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':scratch:')"><img style="margin-bottom: 10px;" alt="scratch" src="http://2img.net/i/fa/i/smiles/icon_scratch.png" title="scratch" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':study:')"><img style="margin-bottom: 10px;" alt="study" src="http://2img.net/i/fa/i/smiles/icon_study.png" title="study" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':elephant:')"><img style="margin-bottom: 10px;" alt="elephant" src="http://2img.net/i/fa/i/smiles/icon_elephant.png" title="elephant" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':flower:')"><img style="margin-bottom: 10px;" alt="flower" src="http://2img.net/i/fa/i/smiles/icon_flower.png" title="flower" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':afro:')"><img style="margin-bottom: 10px;" alt="afro" src="http://2img.net/i/fa/i/smiles/icon_rr.png" title="afro" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':lol!:')"><img style="margin-bottom: 10px;" alt="lol!" src="http://2img.net/i/fa/i/smiles/lol.gif" title="lol!" /></a> </span>
</td>
</tr>
</tbody>
</table>
</div>
<div class="popupWrapper" id="editShout_popup" style="display: none; top: 50%; left: 50%; width: 650px; height: 245px; margin:-135px 0 0 -325px; position: absolute;">
<div class="popupInner" id="editShout_inner" style="width: 650px; height: 245px;">
<h3>
Editar Shout
</h3>
<div class="message error block_wrap" id="shoutbox-inline-error-editShout" style="display:none;">
</div>
<div class="ipsPad">
<span class="cke_wrapper cke_ltr" role="presentation"> </span>
<form style="" onsubmit="submitEditedMsg('?archives=1');return false;" method="post" action="" name="editpost">
<table class="cke_editor" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr style="-moz-user-select: none;">
<td>
<span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('bold', 'editarea')" type="button" accesskey="b" title="Negrito">
<img src="http://2img.net/i/fa/wysiwyg/text_bold.png" alt="Negrito" title="Negrito" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('italic', 'editarea')" type="button" accesskey="i" title="Itálico">
<img src="http://2img.net/i/fa/wysiwyg/text_italic.png" alt="Itál" title="Itálico" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('underline', 'editarea')" type="button" accesskey="u" title="Sublinhar">
<img src="http://2img.net/i/fa/wysiwyg/text_underline.png" alt="Sub" title="Sublinhar" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('left', 'editarea')" type="button" accesskey="m" title="Esquerda">
<img src="http://2img.net/i/fa/wysiwyg/text_align_left.png" alt="Esq" title="Esquerda" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('center', 'editarea')" type="button" accesskey="t" title="Centralizar">
<img src="http://2img.net/i/fa/wysiwyg/text_align_center.png" alt="Cent" title="Centralizar" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('right', 'editarea')" type="button" accesskey="g" title="Direita">
<img src="http://2img.net/i/fa/wysiwyg/text_align_right.png" alt="Dir" title="Direita" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('list', 'editarea')" type="button" accesskey="l" title="Lista simples">
<img src="http://2img.net/i/fa/wysiwyg/text_list_bullets.png" alt="List" title="Lista simples" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('list=1', 'editarea')" type="button" accesskey="o" title="Lista numerada">
<img src="http://2img.net/i/fa/wysiwyg/text_list_numbers.png" alt="List" title="Lista numarada" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('img', 'editarea')" type="button" accesskey="p" title="Imagem">
<img src="http://2img.net/i/fa/wysiwyg/picture.png" alt="Img" title="Imagem" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('url', 'editarea')" type="button" accesskey="w" title="Link">
<img src="http://2img.net/i/fa/wysiwyg/link.png" alt="Lnk" title="Link" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
</td>
</tr>
<tr>
<td class="cke_contents" style="height: 100px; padding: 0px ! important;">
<textarea class="input_text" id="editarea" name="editarea" style="width: 98%; height: 89%; resize: none; outline: medium none; text-align: left;" onkeydown="number_of_refresh=0;timer_count=0;"> </textarea>
</td>
</tr>
</tbody>
</table>
<div class="short ipsPad">
<div onclick="document.editpost.editarea.focus();timer_count=0;">
<input class="input_submit" value="Enviar Shout" id="submit_button" name="submit_button" type="submit" /> <input class="input_submit alt" value="Limpar" id="shoutbox-clear-button" onclick="document.getElementById('editarea').value = '';" type="button" /> <input class="input_submit alt" value="Cancelar" id="shoutbox-refresh-button" onclick="$('#editShout_popup').toggle();" type="button" />
</div>
</div>
</form><span class="cke_wrapper cke_ltr" role="presentation"> </span>
</div>
</div>
<div class="popupClose clickable" id="editShout_close" onclick="$('#editShout_popup').toggle();">
<img alt="x" src="http://forum.autoitbrasil.com/public/style_images/master/close_popup.png" />
</div>
</div>
<div id="myPrefs_popup" style="display: none; z-index: 10001; top: 10px; left: 395.5px; position: fixed;" class="popupWrapper">
<div id="myPrefs_inner" class="popupInner" style="width: 550px; max-height: 388px;">
<h3>
Painel de Minhas Preferências
</h3>
<div class="ipsBox table_wrap">
<div class="ipsBox_container">
<div style="display: none;" class="message error block_wrap" id="shoutbox-inline-error-myprefs">
</div>
<table class="ipb_table">
<tbody>
<tr>
<td colspan="2">
Aqui você pode mudar suas preferências pessoais para o Shoutbox.<br />Simplesmente atualize as preferências a seu gosto e clique no botão 'Salvar'.
</td>
</tr>
<tr class="row2">
<td colspan="2" class="altrow">
<strong id="shoutbox-popup-status">Preferências</strong>
</td>
</tr>
<tr>
<td class="short" style="width: 50%;">
<strong>Mostrar o Shoutbox Global?</strong> <br /> <label for="my_prefs_gsb_y">Sim</label> <input checked="" id="my_prefs_gsb_y" value="1" name="my_prefs_gsb" class="input_radio" type="radio" /> <input id="my_prefs_gsb_n" value="0" name="my_prefs_gsb" class="input_radio" type="radio" /> <label for="my_prefs_gsb_n">Não</label>
</td>
<td class="short" style="width: 50%;">
<strong>A <em>Tecla Enter</em> deverá agir como o botão 'Enviar Shout'?</strong> <br /> <label for="my_prefs_ets_y">Sim</label> <input id="my_prefs_ets_y" value="1" name="my_prefs_ets" class="input_radio" type="radio" /> <input checked="" id="my_prefs_ets_n" value="0" name="my_prefs_ets" class="input_radio" type="radio" /> <label for="my_prefs_ets_n">Não</label>
</td>
</tr>
<tr>
<td class="short">
<strong>Mostrar o botão Atualizar?</strong> <br /> <label for="my_prefs_drb_y">Sim</label> <input checked="" id="my_prefs_drb_y" value="1" name="my_prefs_drb" class="input_radio" type="radio" /> <input id="my_prefs_drb_n" value="0" name="my_prefs_drb" class="input_radio" type="radio" /> <label for="my_prefs_drb_n">Não</label>
</td>
<td class="short">
<strong>Habilitar Comandos Rápidos?</strong> <br /> <label for="my_prefs_eqc_y">Sim</label> <input checked="" id="my_prefs_eqc_y" value="1" name="my_prefs_eqc" class="input_radio" type="radio" /> <input id="my_prefs_eqc_n" value="0" name="my_prefs_eqc" class="input_radio" type="radio" /> <label for="my_prefs_eqc_n">Não</label>
</td>
</tr>
<tr>
<td class="short">
<strong>Shoutbox display order?</strong>
</td>
<td class="short">
<select id="my_prefs_sdo" name="my_prefs_sdo"> <option selected="" value="">Default</option> <option value="1">Older -> Newer</option> <option value="2">Newer -> Older</option> </select> <br /> <span class="error">Manual refresh req'd if changed</span>
</td>
</tr>
<tr>
<td colspan="2" class="short">
<input class="input_submit" value="Salvar Preferências" id="myprefs_save" type="button" /> <input class="ipsButton_secondary" value="Restaurar Padrão" id="myprefs_restore" type="button" />
</td>
</tr>
</tbody>
Para facilitar o entendimento os código que uso são esses...
J.S
- Código:
function updateIframeSize(x,y){
if (x != '') {
$('#' + x).height(y + 10 + 'px');
}
}
$(function() {
$('#page-body').prepend('<iframe id="iframe_shoutbox" height="360px" width="100%" frameBorder="0" src="/h5-">Your browser does not support IFRAMEs</iframe>');
});
HTML
[code:1:c6c4] <!--
// Copyright? (c) 2013 JScript <jscriptbrasil at live.com>
// This work is free. You can redistribute it and/or modify it
// under the terms of the WTFPL, Version 2
// Based on IPBoard ShoutBox, all rights reserved!
--> <title>Chatbox</title> <meta content="text/html; charset=utf-8" http-equiv="content-type" /> <meta content="text/javascript" http-equiv="content-script-type" /> <meta content="text/css" http-equiv="content-style-type" /> <link href="http://illiweb.com/fa/favicon/write.ico" type="image/x-icon" rel="shortcut icon" /> <link type="text/css" href="https://googledrive.com/host/0BywKunb3ieyDdVlWcUlScmk2SlE/ShoutBox.css" rel="stylesheet" /> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> <script type="text/javascript" src="https://googledrive.com/host/0BywKunb3ieyDdVlWcUlScmk2SlE/lz-string-1.3.0-rc1.js"></script> <script type="text/javascript" src="https://googledrive.com/host/0BywKunb3ieyDaW5OTFJCWl95VzA/ShoutBox.js" charset="ISO-8859-1"></script> <script type="text/javascript">
//<![CDATA[
var params = '?archives=1';
var smilies_sid = '';
var url_chat = '/chatbox/index.forum';
//]]>
</script> <style type="text/css">
* {margin: 0;padding: 0;}
html, body {overflow: hidden;}
body {padding: 0;margin: 0;background-color: #fbfbfb; font-family: helvetica,arial,sans-serif !important}
.fontbutton {border:0;}
</style>
<div id="ajax_loading" style="display: none;">
<img alt="Carregando..." src="http://i69.servimg.com/u/f69/18/17/62/92/ajax_l10.gif" />
</div>
<div id="shoutbox-temp-msgs" style="display: none;">
</div>
<div id="shoutbox-temp-imgs" style="display: none;">
</div>
<div id="category_shoutbox" class="category_block block_wrap" style="min-height: 300px; min-width: 720px; width: 100%;">
<h3 class="maintitle">
<a title="Fechar/Abrir shoutbox" href="#" class="toggle right">Fechar/Abrir shoutbox</a> <a title="View Main Shoutbox" href="#" target="_top">IPBoard Chat (v1.1112pr) </a>
</h3>
<div class="ipsBox table_wrap">
<div class="ipsBox_container">
<table class="ipb_table shoutbox_table" style="height: 230px; min-height: 230px;">
<tbody>
<tr class="row2" id="shoutbox-announcement-row">
<td colspan="2" class="altrow" valign="middle">
<div class="message" id="shoutbox-announcement-text">
A ofensa a outro membro / Staff é sujeito a punições. <strong class="bbc">O ChatBox é um lugar para descontração, não de ajuda e suporte!</strong>
</div>
</td>
</tr>
<tr class="row1">
<td colspan="2" class="altrow" valign="top">
<div id="shoutbox-shouts" style="overflow: auto; overflow-x: hidden; left: 0px; top: 0px; height: 169px; min-height: 128px;">
<p id="shoutbox-inactive-prompt" style="display: none; height: 126px;" class="altrow short">
<br />Nós percebemos que você esteve inativo por mais de 10 minutos.<br /> O shoutbox parou de ser executado devido a sua inatividade.<br /> Se você está de volta, por favor clique no botão abaixo <span style="text-decoration: underline;">Estou de Volta!</span>. <br /><br /> <input onclick="I_am_back();" class="input_submit" value="Estou de Volta!" type="button" />
</p>
<p id="shoutbox-service" style="display: none; height: 126px;" class="altrow short">
<br /><br />Nosso shoutbox está passando por manutenção neste momento, agradecemos a sua compreênção!<br /> Em breve estaremos funcionando normalmente, grato pela sua visita...<br /> O shoutbox parou de ser executado por motivos técnicos. <br />
</p>
<div id="chatbox_members" style="display: none;" increment="10" pageincrement="144" maxpos="460" curpos="0">
</div>
<table id="shoutbox-shouts-table" style="display: ;">
<tbody id="chatbox_general" class="chat_toggle" style="display: ;" curpos="188" maxpos="325" pageincrement="0" increment="10">
<!-- General ChatBox content -->
</tbody>
<tbody id="chatbox_mpreceive" class="chat_toggle" style="display: none;" curpos="188" maxpos="325" pageincrement="0" increment="10">
<!-- Private Receive Message ChatBox content -->
</tbody>
<tbody id="chatbox_mpsend" class="chat_toggle" style="display: none;" curpos="188" maxpos="325" pageincrement="0" increment="10">
<!-- Private Send Message ChatBox content -->
</tbody>
</table>
</div>
<div id="shouts-global-resizer" title="Clique para redimensionar o ShoutBox!" onmousedown="resizeElement();">
</div>
<div style="display: none;" class="message error block_wrap" id="shoutbox-inline-error-glb">
</div>
</td>
</tr>
<!-- Buttons -->
<tr class="row1">
<td colspan="2" class="altrow" valign="top">
<form onsubmit="submitmsg('?archives=1');return false;" method="post" action="" name="post">
<div id="chatbox_messenger_form" style="display: ">
<div onclick="document.post.message.focus();timer_count=0;">
<input id="message" name="message" size="70" maxlength="1024" class="input_text" autocomplete="off" onkeydown="number_of_refresh=0;timer_count=0;" type="text" /> <input class="input_submit" value="Enviar Shout" id="submit_button" name="submit_button" type="submit" /> <input class="input_submit alt" value="Limpar" id="shoutbox-clear-button" onclick="document.getElementById('message').value = '';" type="button" /> <input class="input_submit alt" value="Atualizar" id="shoutbox-refresh-button" style="" onclick="refresh_chatbox('?archives=1');" type="button" /> <input data-scope="shoutbox" onclick="do_selectsmilies(event);" class="input_submit alt" value="Smilies" id="divsmilies" type="button" /> <input class="input_submit alt" value="BBCode" id="shoutbox-bbcode-button" onclick="window.open('/faq?mode=bbcode','BBCodes Help','status=no,location=no,toolbar=no,menubar=no,personalbar=no,width=640,height=window.innerHeight,scrollbars=yes,resizable=yes,left=0,top=0'); return false;" type="button" /> <input class="input_submit alt" value="Preferências" id="shoutbox-myprefs-button" onclick="$('#myPrefs_popup').toggle();" type="button" />
</div>
</div>
</form>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<!-- Smiles -->
<div id="shoutbox-smilies-button_menucontent" style="display: none; width: 400px; position: absolute; z-index: 9999; top: 1px; left: 1px;">
<h3 class="maintitle short">
<span class="pager"><a id="page_0" class="emoticonPager" href="#">«</a> </span> More <span class="pager"> <a id="page_1" class="emoticonPager" href="#">»</a></span>
</h3>
<table class="ipb_table" style="background: none repeat scroll 0 0 #FFFFFF;">
<tbody>
<tr id="smile_row" class="row1">
<td>
<span> <a style="margin-left: 10px;" href="#" onclick="copy_user_name(':sos:')"> <img style="margin-bottom: 10px;" alt="No Like!" src="http://r19.imgfast.net/users/1917/43/09/52/smiles/632187147.gif" title="SOS" /> </a> <a style="margin-left: 10px;" href="#" onclick="copy_user_name(':D')"> <img style="margin-bottom: 10px;" alt="Very Happy" src="http://2img.net/i/fa/i/smiles/icon_biggrin.png" title="Very Happy" /> </a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':)')"><img style="margin-bottom: 10px;" alt="Smile" src="http://2img.net/i/fa/i/smiles/icon_smile.gif" title="Smile" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':(')"><img style="margin-bottom: 10px;" alt="Sad" src="http://2img.net/i/fa/i/smiles/icon_sad.gif" title="Sad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':o')"><img style="margin-bottom: 10px;" alt="Surprised" src="http://2img.net/i/fa/i/smiles/icon_surprised.gif" title="Surprised" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name('<img src=" http:="" illiweb.com="" fa="" i="" smiles="" icon_eek.gif"="" alt="Shocked" longdesc="42">')"><img style="margin-bottom: 10px;" alt="Shocked" src="http://2img.net/i/fa/i/smiles/icon_eek.gif" title="Shocked" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name('8)')"><img style="margin-bottom: 10px;" alt="Cool" src="http://2img.net/i/fa/i/smiles/icon_cool.gif" title="Cool" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':lol:')"><img style="margin-bottom: 10px;" alt="Laughing" src="http://2img.net/i/fa/i/smiles/icon_lol.gif" title="Laughing" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':x')"><img style="margin-bottom: 10px;" alt="Mad" src="http://2img.net/i/fa/i/smiles/icon_mad.gif" title="Mad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':P')"><img style="margin-bottom: 10px;" alt="Razz" src="http://2img.net/i/fa/i/smiles/icon_razz.gif" title="Razz" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':oops:')"><img style="margin-bottom: 10px;" alt="Embarassed" src="http://2img.net/i/fa/i/smiles/icon_redface.gif" title="Embarassed" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cry:')"><img style="margin-bottom: 10px;" alt="Crying or Very sad" src="http://2img.net/i/fa/i/smiles/icon_cry.gif" title="Crying or Very sad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':evil:')"><img style="margin-bottom: 10px;" alt="Evil or Very Mad" src="http://2img.net/i/fa/i/smiles/icon_evil.gif" title="Evil or Very Mad" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':twisted:')"><img style="margin-bottom: 10px;" alt="Twisted Evil" src="http://2img.net/i/fa/i/smiles/icon_twisted.gif" title="Twisted Evil" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':roll:')"><img style="margin-bottom: 10px;" alt="Rolling Eyes" src="http://2img.net/i/fa/i/smiles/icon_rolleyes.gif" title="Rolling Eyes" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(';)')"><img style="margin-bottom: 10px;" alt="Wink" src="http://2img.net/i/fa/i/smiles/icon_wink.gif" title="Wink" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':!:')"><img style="margin-bottom: 10px;" alt="Exclamation" src="http://2img.net/i/fa/i/smiles/icon_exclaim.gif" title="Exclamation" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':?:')"><img style="margin-bottom: 10px;" alt="Question" src="http://2img.net/i/fa/i/smiles/icon_question.gif" title="Question" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':idea:')"><img style="margin-bottom: 10px;" alt="Idea" src="http://2img.net/i/fa/i/smiles/icon_idea.png" title="Idea" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':arrow:')"><img style="margin-bottom: 10px;" alt="Arrow" src="http://2img.net/i/fa/i/smiles/icon_arrow.gif" title="Arrow" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':|')"><img style="margin-bottom: 10px;" alt="Neutral" src="http://2img.net/i/fa/i/smiles/icon_neutral.gif" title="Neutral" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':face:')"><img style="margin-bottom: 10px;" alt="What a Face" src="http://2img.net/i/fa/i/smiles/fresse.png" title="What a Face" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':star:')"><img style="margin-bottom: 10px;" alt="Like a Star @ heaven" src="http://2img.net/i/fa/i/smiles/star3.png" title="Like a Star @ heaven" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':suspect:')"><img style="margin-bottom: 10px;" alt="Suspect" src="http://2img.net/i/fa/i/smiles/suspect.gif" title="Suspect" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':heart:')"><img style="margin-bottom: 10px;" alt="I love you" src="http://2img.net/i/fa/i/smiles/herz.png" title="I love you" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':no:')"><img style="margin-bottom: 10px;" alt="No" src="http://2img.net/i/fa/i/smiles/kopfschuettel.gif" title="No" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name('<img src=" users="" 2117="" 37="" 44="" 56="" smiles="" 3350979868.gif"="" alt="Bravo" longdesc="9">')"><img style="margin-bottom: 10px;" alt="@" src="http://2img.net/i/fa/i/smiles/at.png" title="@" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cyclops:')"><img style="margin-bottom: 10px;" alt="cyclops" src="http://2img.net/i/fa/i/smiles/icon_cyclops.gif" title="cyclops" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':clown:')"><img style="margin-bottom: 10px;" alt="clown" src="http://2img.net/i/fa/i/smiles/icon_clown.png" title="clown" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':pirat:')"><img style="margin-bottom: 10px;" alt="pirat" src="http://2img.net/i/fa/i/smiles/icon_pirat.png" title="pirat" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':tongue:')"><img style="margin-bottom: 10px;" alt="tongue" src="http://2img.net/i/fa/i/smiles/icon_tongue.png" title="tongue" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':silent:')"><img style="margin-bottom: 10px;" alt="silent" src="http://2img.net/i/fa/i/smiles/icon_silent.png" title="silent" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':pale:')"><img style="margin-bottom: 10px;" alt="pale" src="http://2img.net/i/fa/i/smiles/icon_pale.gif" title="pale" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':alien:')"><img style="margin-bottom: 10px;" alt="alien" src="http://2img.net/i/fa/i/smiles/alien.png" title="alien" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cat:')"><img style="margin-bottom: 10px;" alt="cat" src="http://2img.net/i/fa/i/smiles/icon_cat.png" title="cat" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':monkey:')"><img style="margin-bottom: 10px;" alt="monkey" src="http://2img.net/i/fa/i/smiles/icon_monkey.png" title="monkey" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':pig:')"><img style="margin-bottom: 10px;" alt="pig" src="http://2img.net/i/fa/i/smiles/icon_porc.png" title="pig" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':rabbit:')"><img style="margin-bottom: 10px;" alt="rabbit" src="http://2img.net/i/fa/i/smiles/icon_rabbit.png" title="rabbit" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':bounce:')"><img style="margin-bottom: 10px;" alt="bounce" src="http://2img.net/i/fa/i/smiles/icon_bounce.gif" title="bounce" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':confused:')"><img style="margin-bottom: 10px;" alt="confused" src="http://2img.net/i/fa/i/smiles/confused.png" title="confused" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':affraid:')"><img style="margin-bottom: 10px;" alt="affraid" src="http://2img.net/i/fa/i/smiles/affraid.gif" title="affraid" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':bball:')"><img style="margin-bottom: 10px;" alt="Basketball" src="http://2img.net/i/fa/i/smiles/icon_basketball.gif" title="Basketball" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cheers:')"><img style="margin-bottom: 10px;" alt="cheers" src="http://2img.net/i/fa/i/smiles/icon_cheers.png" title="cheers" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':bom:')"><img style="margin-bottom: 10px;" alt="bom" src="http://2img.net/i/fa/i/smiles/bom.png" title="bom" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':drunken:')"><img style="margin-bottom: 10px;" alt="drunken" src="http://2img.net/i/fa/i/smiles/drunken_smilie.png" title="drunken" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':sleep:')"><img style="margin-bottom: 10px;" alt="Sleep" src="http://2img.net/i/fa/i/smiles/sleep.gif" title="Sleep" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':sunny:')"><img style="margin-bottom: 10px;" alt="sunny" src="http://2img.net/i/fa/i/smiles/icon_sunny.png" title="sunny" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':albino:')"><img style="margin-bottom: 10px;" alt="albino" src="http://2img.net/i/fa/i/smiles/icon_albino.png" title="albino" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':cherry:')"><img style="margin-bottom: 10px;" alt="cherry" src="http://2img.net/i/fa/i/smiles/icon_cherry.png" title="cherry" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':santa:')"><img style="margin-bottom: 10px;" alt="santa" src="http://2img.net/i/fa/i/smiles/icon_santa.png" title="santa" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':rendeer:')"><img style="margin-bottom: 10px;" alt="rendeer" src="http://2img.net/i/fa/i/smiles/icon_rendeer.png" title="rendeer" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':farao:')"><img style="margin-bottom: 10px;" alt="farao" src="http://2img.net/i/fa/i/smiles/icon_farao.png" title="farao" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':king:')"><img style="margin-bottom: 10px;" alt="king" src="http://2img.net/i/fa/i/smiles/icon_king.png" title="king" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':queen:')"><img style="margin-bottom: 10px;" alt="queen" src="http://2img.net/i/fa/i/smiles/icon_queen.png" title="queen" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':joker:')"><img style="margin-bottom: 10px;" alt="jocolor" src="http://2img.net/i/fa/i/smiles/icon_jokercolor.png" title="jocolor" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':geek:')"><img style="margin-bottom: 10px;" alt="geek" src="http://2img.net/i/fa/i/smiles/icon_geek.png" title="geek" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':scratch:')"><img style="margin-bottom: 10px;" alt="scratch" src="http://2img.net/i/fa/i/smiles/icon_scratch.png" title="scratch" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':study:')"><img style="margin-bottom: 10px;" alt="study" src="http://2img.net/i/fa/i/smiles/icon_study.png" title="study" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':elephant:')"><img style="margin-bottom: 10px;" alt="elephant" src="http://2img.net/i/fa/i/smiles/icon_elephant.png" title="elephant" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':flower:')"><img style="margin-bottom: 10px;" alt="flower" src="http://2img.net/i/fa/i/smiles/icon_flower.png" title="flower" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':afro:')"><img style="margin-bottom: 10px;" alt="afro" src="http://2img.net/i/fa/i/smiles/icon_rr.png" title="afro" /></a><a style="margin-left: 10px;" href="#" onclick="copy_user_name(':lol!:')"><img style="margin-bottom: 10px;" alt="lol!" src="http://2img.net/i/fa/i/smiles/lol.gif" title="lol!" /></a> </span>
</td>
</tr>
</tbody>
</table>
</div>
<div class="popupWrapper" id="editShout_popup" style="display: none; top: 50%; left: 50%; width: 650px; height: 245px; margin:-135px 0 0 -325px; position: absolute;">
<div class="popupInner" id="editShout_inner" style="width: 650px; height: 245px;">
<h3>
Editar Shout
</h3>
<div class="message error block_wrap" id="shoutbox-inline-error-editShout" style="display:none;">
</div>
<div class="ipsPad">
<span class="cke_wrapper cke_ltr" role="presentation"> </span>
<form style="" onsubmit="submitEditedMsg('?archives=1');return false;" method="post" action="" name="editpost">
<table class="cke_editor" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr style="-moz-user-select: none;">
<td>
<span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('bold', 'editarea')" type="button" accesskey="b" title="Negrito">
<img src="http://2img.net/i/fa/wysiwyg/text_bold.png" alt="Negrito" title="Negrito" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('italic', 'editarea')" type="button" accesskey="i" title="Itálico">
<img src="http://2img.net/i/fa/wysiwyg/text_italic.png" alt="Itál" title="Itálico" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('underline', 'editarea')" type="button" accesskey="u" title="Sublinhar">
<img src="http://2img.net/i/fa/wysiwyg/text_underline.png" alt="Sub" title="Sublinhar" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('left', 'editarea')" type="button" accesskey="m" title="Esquerda">
<img src="http://2img.net/i/fa/wysiwyg/text_align_left.png" alt="Esq" title="Esquerda" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('center', 'editarea')" type="button" accesskey="t" title="Centralizar">
<img src="http://2img.net/i/fa/wysiwyg/text_align_center.png" alt="Cent" title="Centralizar" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('right', 'editarea')" type="button" accesskey="g" title="Direita">
<img src="http://2img.net/i/fa/wysiwyg/text_align_right.png" alt="Dir" title="Direita" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('list', 'editarea')" type="button" accesskey="l" title="Lista simples">
<img src="http://2img.net/i/fa/wysiwyg/text_list_bullets.png" alt="List" title="Lista simples" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('list=1', 'editarea')" type="button" accesskey="o" title="Lista numerada">
<img src="http://2img.net/i/fa/wysiwyg/text_list_numbers.png" alt="List" title="Lista numarada" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('img', 'editarea')" type="button" accesskey="p" title="Imagem">
<img src="http://2img.net/i/fa/wysiwyg/picture.png" alt="Img" title="Imagem" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
<button style="width: 100%; display: block; padding-bottom: 5px;" class="input_submit alt" onclick="BBCode_Add('url', 'editarea')" type="button" accesskey="w" title="Link">
<img src="http://2img.net/i/fa/wysiwyg/link.png" alt="Lnk" title="Link" />
</button><span id="text_editor" style="width: 100%; display: block; padding-bottom: 5px;"> </span>
</td>
</tr>
<tr>
<td class="cke_contents" style="height: 100px; padding: 0px ! important;">
<textarea class="input_text" id="editarea" name="editarea" style="width: 98%; height: 89%; resize: none; outline: medium none; text-align: left;" onkeydown="number_of_refresh=0;timer_count=0;"> </textarea>
</td>
</tr>
</tbody>
</table>
<div class="short ipsPad">
<div onclick="document.editpost.editarea.focus();timer_count=0;">
<input class="input_submit" value="Enviar Shout" id="submit_button" name="submit_button" type="submit" /> <input class="input_submit alt" value="Limpar" id="shoutbox-clear-button" onclick="document.getElementById('editarea').value = '';" type="button" /> <input class="input_submit alt" value="Cancelar" id="shoutbox-refresh-button" onclick="$('#editShout_popup').toggle();" type="button" />
</div>
</div>
</form><span class="cke_wrapper cke_ltr" role="presentation"> </span>
</div>
</div>
<div class="popupClose clickable" id="editShout_close" onclick="$('#editShout_popup').toggle();">
<img alt="x" src="http://forum.autoitbrasil.com/public/style_images/master/close_popup.png" />
</div>
</div>
<div id="myPrefs_popup" style="display: none; z-index: 10001; top: 10px; left: 395.5px; position: fixed;" class="popupWrapper">
<div id="myPrefs_inner" class="popupInner" style="width: 550px; max-height: 388px;">
<h3>
Painel de Minhas Preferências
</h3>
<div class="ipsBox table_wrap">
<div class="ipsBox_container">
<div style="display: none;" class="message error block_wrap" id="shoutbox-inline-error-myprefs">
</div>
<table class="ipb_table">
<tbody>
<tr>
<td colspan="2">
Aqui você pode mudar suas preferências pessoais para o Shoutbox.<br />Simplesmente atualize as preferências a seu gosto e clique no botão 'Salvar'.
</td>
</tr>
<tr class="row2">
<td colspan="2" class="altrow">
<strong id="shoutbox-popup-status">Preferências</strong>
</td>
</tr>
<tr>
<td class="short" style="width: 50%;">
<strong>Mostrar o Shoutbox Global?</strong> <br /> <label for="my_prefs_gsb_y">Sim</label> <input checked="" id="my_prefs_gsb_y" value="1" name="my_prefs_gsb" class="input_radio" type="radio" /> <input id="my_prefs_gsb_n" value="0" name="my_prefs_gsb" class="input_radio" type="radio" /> <label for="my_prefs_gsb_n">Não</label>
</td>
<td class="short" style="width: 50%;">
<strong>A <em>Tecla Enter</em> deverá agir como o botão 'Enviar Shout'?</strong> <br /> <label for="my_prefs_ets_y">Sim</label> <input id="my_prefs_ets_y" value="1" name="my_prefs_ets" class="input_radio" type="radio" /> <input checked="" id="my_prefs_ets_n" value="0" name="my_prefs_ets" class="input_radio" type="radio" /> <label for="my_prefs_ets_n">Não</label>
</td>
</tr>
<tr>
<td class="short">
<strong>Mostrar o botão Atualizar?</strong> <br /> <label for="my_prefs_drb_y">Sim</label> <input checked="" id="my_prefs_drb_y" value="1" name="my_prefs_drb" class="input_radio" type="radio" /> <input id="my_prefs_drb_n" value="0" name="my_prefs_drb" class="input_radio" type="radio" /> <label for="my_prefs_drb_n">Não</label>
</td>
<td class="short">
<strong>Habilitar Comandos Rápidos?</strong> <br /> <label for="my_prefs_eqc_y">Sim</label> <input checked="" id="my_prefs_eqc_y" value="1" name="my_prefs_eqc" class="input_radio" type="radio" /> <input id="my_prefs_eqc_n" value="0" name="my_prefs_eqc" class="input_radio" type="radio" /> <label for="my_prefs_eqc_n">Não</label>
</td>
</tr>
<tr>
<td class="short">
<strong>Shoutbox display order?</strong>
</td>
<td class="short">
<select id="my_prefs_sdo" name="my_prefs_sdo"> <option selected="" value="">Default</option> <option value="1">Older -> Newer</option> <option value="2">Newer -> Older</option> </select> <br /> <span class="error">Manual refresh req'd if changed</span>
</td>
</tr>
<tr>
<td colspan="2" class="short">
<input class="input_submit" value="Salvar Preferências" id="myprefs_save" type="button" /> <input class="ipsButton_secondary" value="Restaurar Padrão" id="myprefs_restore" type="button" />
</td>
</tr>
</tbody>
Re: Como adicionar opções moderativas no Chatbox?
Olá!
Abra e leia o conteúdo do Spoiler:
Shek
Tópico movido de 'Questões sobre a aparência do fórum' para 'Questões sobre JavaScript & jQuery'
Abra e leia o conteúdo do Spoiler:
- Spoiler:
Chatbox
Este tutorial trás para a visão dos administradores, a capacidade de editar mensagens e excluí-las do chatbox. Se tiver direitos administrativos, poderá controlar todas as mensagens, caso contrário poderá mudar somente a sua.
--> Tutoriais, dicas e astúcias <--
Avatar e edição de mensagens!
1º - Aplicação do código javascript:
As páginas javascript ativas em seu fórum possibilita inserir scripts e jquery para personalizar seu fórum, contudo é importante saber que qualquer script encontrado na internet acabam por não surgir efeito nos fóruns.
Painel de controle >> Módulos >> HTML & JavaScript >> Gestão dos códigos JavaScripts >>
Título Correspondente ao nome da página JavaScript/jQuery que será criada. Localização- São destinados os devidos locais para onde você aplicará os efeitos do JavaScript nos fóruns. No nosso caso, aplicaremos No índice. Código JavaScript Campo destinado para receber os códigos JavaScript e jQuery. Habilitar o gerenciamento dos códigos JavaScript Ao selecionar a opção sim, estará ativando a função páginas Javascript no seu fórum. Se selecionar não, as páginas serão desabilitadas no fórum.
2º - Código a ser utilizado:
Em seguida, cole o seguinte código em sua página Javascript:
- Código:
/**************************************************************************
* Module: AVATARChat + JS_EditMsgChat
* Description: Need?!
* Author: Made and Optimizations by JScript - 2014/11/23
* Version: RC2 (Release candidate 2!)
***************************************************************************/
function insertChatBox(chatbox_id, chatbox_url) {
return insertChatBoxNew(chatbox_id, chatbox_url);
}
// Redefine function in frm_lang_xx.js, by JScript Brasil at live dot com!
function insertChatBoxNew(chatbox_id, chatbox_url) {
document.getElementById(chatbox_id).innerHTML = '<iframe src="/chatbox/index.forum?archives=1" id="frame_chatbox" scrolling="no" width="100%" height="100%" marginwidth="0" marginheight="0" frameborder="0"></iframe>';
frames["frame_chatbox"].onload = function() {
// Redefine function in chatbox7.js, by JScript Brasil at live dot com!
var JS_search = {
//inVar: /">\[(?:(?:2[0-3]|[0-1][0-9]|[0-9]):[0-5][0-9]:[0-5][0-9])\]<\/span> <span class=\\"user-msg\\">(.+)Ιid=(.*?)Α<(.*?)>Ε<img (.*?)Χ<img (.*?)>Τ(.+)Μ(.*?)<\/span>/g,
//inHtml: /">\[(?:(?:2[0-3]|[0-1][0-9]|[0-9]):[0-5][0-9]:[0-5][0-9])\]<\/span> <span class=\\"user-msg\\">(.+)[\u0399]id=(.*?)[\u0391]<(.*?)>[\u0395]<img (.*?)[\u03a7]<img (.*?)>[\u039c](.*?)<\/span>/g
inVar: /Ιid=(.*?)Α<(.*?)>Ε<img (.*?)Χ<img (.*?)>Μ(.*?)<\/span>/g,
inHtml: /[\u0399]id=(.*?)[\u0391]<(.*?)>[\u0395]<img (.*?)[\u03a7]<img (.*?)>[\u039c](.*?)<\/span>/g
},
// JS_replace = '">[$6]$1<span class=\"id\" id=$2><span class=\"js-avatar\"><$3></span><span class=\"editor\"><img onclick=\"editor(this, 1)\" $4<img onclick=\"editor(this, 2)\" $5></span><span class=\"text\">$7</span>',
JS_replace = '<span class=\"id\" id=$1><span class=\"js-avatar\"><$2></span><span class=\"editor\"><img onclick=\"editor(this, 1)\" $3<img onclick=\"editor(this, 2)\" $4></span><span class=\"text\">$5</span>',
oIframe = (document.getElementById("frame_chatbox").contentWindow || document.getElementById("frame_chatbox").contentDocument),
script = oIframe.document.createElement("script"),
memDiv = oIframe.document.createElement('div');
script.type = "text/javascript";
script.innerHTML =
'USERNAME = parent._userdata.username;' +
'SUPERMOD = parent._userdata.user_level;' +
'AVATAR = parent._userdata.avatar.replace(\'<img src="\', "[img]").replace(\'" alt="" />\', "[/img]");' +
'JS_search = ' + JS_search.inVar + ';' +
'JS_replace = \'' + JS_replace + '\';' +
'function submitmsg(params) {' +
' if (document.post.message.value.length < 4 && SUPERMOD !== 1) return false;' +
' if (document.post.message.value.indexOf("/") !== 0) {' +
' var date = new Date();' +
' var UID = Math.ceil(date.getDate() + date.getHours() + Math.random() * Math.pow(10, 10) + date.getMinutes() + date.getSeconds() + date.getMilliseconds());' +
' if (UID.length < 10) {' +
' UID + "" + (10 - UID.length);' +
' }' +
//' var time = new Date().toLocaleTimeString();' +
//' document.post.message.value = \'Ιid="\' + UID + \'"Α\' + AVATAR + "Ε[img]http://goo.gl/brvCui[/img]Χ[img]http://goo.gl/k8FZx5[/img]Τ" + time + "Μ" + document.post.message.value;' +
' document.post.message.value = \'Ιid="\' + UID + \'"Α\' + AVATAR + "Ε[img]http://goo.gl/brvCui[/img]Χ[img]http://goo.gl/k8FZx5[/img]Μ" + document.post.message.value;' +
' }' +
' document.post.sent.value = document.post.message.value;' +
' document.post.message.value = "";' +
' document.post.message.focus();' +
' ajax_submit_chatbox(params);' +
' return false' +
'}' +
'function copy_user_name(user_name) {' +
' if (document.post.message) {' +
' document.post.message.focus();' +
' document.post.message.value += ((user_name.indexOf("@") == 0) ? "" : "@") + user_name + " -> ";' +
' }' +
' return false' +
'}' +
'function ajax_submit_chatbox(params, editor) {' +
' number_of_refresh = 0;' +
' if (params == "" || params == undefined) {' +
' params = "?achives=0"' +
' }' +
' if (editor == "" || editor == undefined) {' +
' var msg_sent = document.post.sent.value;' +
' } else {' +
' var msg_sent = editor;' +
' }' +
' var data = "&mode=send";' +
' data += "&sent=" + encodeURIComponent(msg_sent);' +
' data += "&sbold=" + document.post.sbold.value;' +
' data += "&sitalic=" + document.post.sitalic.value;' +
' data += "&sunderline=" + document.post.sunderline.value;' +
' data += "&sstrike=" + document.post.sstrike.value;' +
' data += "&scolor=" + document.post.scolor.value;' +
' if ((msg_sent.indexOf("/away") == 0) || (msg_sent.indexOf("/abs") == 0)) {' +
' document.getElementById("refresh_auto").checked = false' +
' }' +
' if (document.post.sent.value == "/banlist") {' +
' window.open("/chatbox/chatbox_banlist.forum" + params, "banlist", "toolbar=no,menubar=no,personalbar=no,width=450,height=300,scrollbars=yes,resizable=yes");' +
' return false' +
' }' +
' $.ajax({' +
' url: "/chatbox/chatbox_actions.forum" + params,' +
' type: "post",' +
' data: data,' +
' dataType: "script",' +
' success: function(response, status, xhr) {' +
' if (xhr.status == 200) {' +
//' if (typeof (chatbox_messages) !== "undefined") {' +
' chatbox_messages = chatbox_messages.replace(JS_search, JS_replace);' +
' document.getElementById("memdiv").innerHTML = chatbox_messages;' +
' hackMsg();' +
' document.getElementById("chatbox").innerHTML = document.getElementById("memdiv").innerHTML;' +
' /*$("#chatbox").html(chatbox_messages) [0].scrollTop = $("#chatbox").prop("scrollHeight");*/' +
' document.getElementById("chatbox").scrollTop = 999999;' +
//' }' +
' if (typeof (chatbox_memberlist) !== "undefined") {' +
' document.getElementById("chatbox_members").innerHTML = chatbox_memberlist;' +
' /*$("#chatbox_members").html(chatbox_memberlist);*/' +
' }' +
' }' +
' },' +
' })' +
'}' +
'function ajax_refresh_chatbox(params, force) {' +
' if (params == "" || params == undefined) {' +
' params = "?achives=0"' +
' }' +
' $.ajax({' +
' url: "/chatbox/chatbox_actions.forum" + params + "&mode=refresh",' +
' type: "get",' +
' dataType: "script",' +
' success: function(response, status, xhr) {' +
' if (xhr.status == 200) {' + // || force) {' + <- Fail!
//' if ($("#chatbox").length) {' +
' if (typeof (chatbox_messages) !== "undefined") {' +
' chatbox_messages = chatbox_messages.replace(JS_search, JS_replace);' +
' document.getElementById("memdiv").innerHTML = chatbox_messages;' +
' hackMsg();' +
' document.getElementById("chatbox").innerHTML = document.getElementById("memdiv").innerHTML;' +
' document.getElementById("chatbox").scrollTop = document.getElementById("chatbox").scrollHeight + document.getElementById("chatbox").offsetHeight;' +
' document.getElementById("chatbox").scrollTop = 999999;' +
' }' +
//' if (document.getElementById("chatbox_members").innerHTML != null) document.getElementById("chatbox_members").innerHTML = chatbox_memberlist;' +
' if (typeof (chatbox_memberlist) !== "undefined") {' +
' document.getElementById("chatbox_members").innerHTML = chatbox_memberlist;' +
' /*$("#chatbox_members").html(chatbox_memberlist);*/' +
' }' +
' }' +
' },' +
' })' +
'}' +
'function hackMsg() {' +
' var oTarget = jQuery("#memdiv > p"),' +
' iLen = oTarget.length,' +
' index = 0;' +
' for (; index < iLen; index++) {' +
' var oThis = jQuery(oTarget[index]),' +
' sUserName = oThis.find(".user > a").text(),' +
' ID = oThis.find("span.id");' +
' if (ID.length == 0) {' +
' ID = oThis.find(".msg:last").text();' +
// XORcipher -> ' ID = XORcipher(oThis.find(".msg").text());' +
' var del = ID.match(/^\\/remove[\\u0399](.*?)$/);' +
// XORcipher -> ' var del = ID.match(/^\\/removeΙ(.*?)$/);' +
' if (del !== null) {' +
' var oMsg = oThis.parent().find("#" + del[1]).closest("p");' +
' if (oMsg.length) {' +
//' if (oMsg.find(".user > a").text() == sUserName || SUPERMOD > 0) {' +
' oMsg.remove();' +
//' }' +
' }' +
' }' +
' var edit = ID.match(/^\\/edit[\\u0399]([0-9]+)[\\u039c](.*?)$/);' +
// XORcipher -> ' var edit = ID.match(/^\\/editΙ([0-9]+)Μ(.*?)$/);' +
' if (edit !== null) {' +
' var oMsg = oThis.parent().find("#" + edit[1]);' +
' if (oMsg.length) {' +
//' if (oMsg.closest("p").find(".user > a").text() == sUserName || SUPERMOD > 0) {' +
' oMsg.find("span.text").text(edit[2]);' +
//' }' +
' }' +
' }' +
' /*var nudge = ID.match(/^\\/nudge[\\u0399]([0-9]+)[\\u039d](.*?)$/);' +
' if (nudge !== null) {' +
' var oMsg = oThis.parent().find("#" + nudge[1]);' +
' if (oMsg.length) {' +
' if (nudge[2] == USERNAME) {' +
' // Developing!;' +
' }' +
' }' +
' }*/' +
' oThis.remove();' +
' } else {' +
' if (sUserName !== USERNAME && SUPERMOD == 0) {' +
' ID.find(".editor").remove();' +
' }' +
' }' +
' }' +
'}' +
'function editor(oThis, num) {' +
' if (num == 1 && iConfirm("Tem certeza de que deseja remover esta mensagem?\\n\\n" + jQuery(oThis).closest(".id").text() ) == 1) {' +
' ajax_submit_chatbox("?achives=1", "/removeΙ" + jQuery(oThis).closest(".id").attr("id"));' +
' jQuery(oThis).closest("p").remove();' +
' } else if (num == 2) {' +
' var result = prompt("Editando a frase:", jQuery(oThis).closest(".id").text());' +
' if (result != null) {' +
' ajax_submit_chatbox("?achives=1", "/editΙ" + jQuery(oThis).closest(".id").attr("id") + "Μ" + result);' +
' jQuery(oThis).closest(".id span.text").text(result);' +
' }' +
' /*} else if (num == 3) {' +
' ajax_submit_chatbox("?achives=1", XORcipher("/nudgeΙ" + jQuery(oThis).closest(".id").attr("id") + "Ν" + jQuery(oThis).closest("p").find(".user > a").text()));*/' +
' }' +
'}' +
/*'function XORcipher(sText) {' +
' var key = 2,' +
' result = "",' +
' len = sText.length,' +
' i = 0;' +
' for (; i < len; i++) {' +
' result += String.fromCharCode(key ^ sText.charCodeAt(i));' +
' }' +
' return result;' +
'}' +*/
'function iConfirm(text) {' +
' var iChoice = -1;' +
' if (confirm(text) == true) {' +
' iChoice = 1;' +
' } else {' +
' iChoice = 0;' +
' }' +
' return iChoice;' +
'}';
oIframe.document.getElementsByTagName("head")[0].appendChild(script);
var style = oIframe.document.createElement("style");
style.type = "text/css";
style.innerHTML =
'#chatbox p {' +
' background: none repeat scroll 0 0 #fff;' +
' border-bottom: 1px solid #e3e3e3;' +
' line-height: 1.3em;' +
' padding: 5px;' +
'}' +
'#chatbox span[title] {' +
' color: #8f8f8f !important;' +
' float: right !important;' +
'}' +
'#chatbox .user:not(:empty) {' +
' font-weight: 700;' +
' margin-left: 36px !important;' +
'}' +
'#chatbox .id {' +
' display: block;' +
' margin-top: 3px;' +
'}' +
'#chatbox .js-avatar img {' +
' background: none repeat scroll 0 0 #fff;' +
' border: 1px solid #ddd;' +
' float: left;' +
' height: 30px;' +
' margin-right: 5px;' +
' margin-top: -19px;' +
' max-width: 30px;' +
' padding: 1px;' +
' vertical-align: middle;' +
' width: 30px;' +
'}' +
'#chatbox .editor img {' +
' cursor: pointer;' +
' float: right;' +
' padding-left: 4px;' +
'}' +
'#chatbox {' +
' display: none;' +
'}';
oIframe.document.getElementsByTagName("head")[0].appendChild(style);
var forceConnect = setInterval(function() {
if (oIframe.document.getElementById("chatbox") !== null) {
clearInterval(forceConnect);
memDiv.id = 'memdiv';
oIframe.document.getElementsByTagName('body')[0].appendChild(memDiv);
oIframe.document.getElementById("memdiv").style.display = 'none';
oIframe.document.getElementById("memdiv").innerHTML = oIframe.document.getElementById("chatbox").innerHTML.replace(JS_search.inHtml, JS_replace);
oIframe.hackMsg();
oIframe.document.getElementById("chatbox").innerHTML = oIframe.document.getElementById("memdiv").innerHTML;
if (oIframe.document.getElementById('chatbox_option_disco').style.display == 'none') {
oIframe.CB_disconnect();
}
oIframe.document.getElementById("chatbox_option_with_archives").style.display = 'none';
oIframe.document.getElementById("chatbox_option_without_archives").style.display = 'none';
oIframe.document.getElementById("chatbox").style.display = 'block';
}
}, 250);
};
}
Feito isso, basta manter seu chatbox ativado de acordo com as instruções passadas no FAQ: https://ajuda.forumeiros.com/-t9192.htm
- O Javascript funciona no Chatbox?
O Javascript do fórum não afeta a página /chatbox da maneira que afeta o seu fórum no geral. Queira compreender que para seja funcional, é necessário que o mesmo esteja aplicado exatamente como explicado no tutorial.
- Resultado:
Shek
Tópico movido de 'Questões sobre a aparência do fórum' para 'Questões sobre JavaScript & jQuery'
Re: Como adicionar opções moderativas no Chatbox?
Ele só funciona na página inicial neh?
Nesse caso teria como desbugar o que uso?
Nesse caso teria como desbugar o que uso?
Re: Como adicionar opções moderativas no Chatbox?
Isso se você estiver usando o Chatbox apenas na página inicial.Uatyla escreveu:Ele só funciona na página inicial neh?
Consolado- Hiper Membro
- Membro desde : 09/05/2011
Mensagens : 4243
Pontos : 6128
Re: Como adicionar opções moderativas no Chatbox?
e como desbugar o chat que já uso? pois quero usar o chat no portal!
Re: Como adicionar opções moderativas no Chatbox?
Olá Uatyla!
Então meu caro, pelo que pude perceber é o seguinte motivo do seu chat antigo não funcionar:
Algo do sistema dos chatbox foi editado pelos técnicos, por os links que fazem o chat funcionar estão normal.
Você pode adicionar o seu chatbox natural no portal sim, basta adicionar isso em um widget no centro do portal.
Então meu caro, pelo que pude perceber é o seguinte motivo do seu chat antigo não funcionar:
Algo do sistema dos chatbox foi editado pelos técnicos, por os links que fazem o chat funcionar estão normal.
Você pode adicionar o seu chatbox natural no portal sim, basta adicionar isso em um widget no centro do portal.
- Código:
<iframe src="/chatbox" width="500" height="500"></iframe>
Re: Como adicionar opções moderativas no Chatbox?
Pow deu certo mais como deixar ele assim? Ele ficou normal no widget, mesmo usando o código fornecido pelo Shek.
Re: Como adicionar opções moderativas no Chatbox?
Olá;
Veja essa linha do tutorial que o @Shek lhe passou:
Localização- São destinados os devidos locais para onde você aplicará os efeitos do JavaScript nos fóruns. No nosso caso, aplicaremos No índice.
Marque 'Em todas as páginas', que funcionará.
Veja essa linha do tutorial que o @Shek lhe passou:
Localização- São destinados os devidos locais para onde você aplicará os efeitos do JavaScript nos fóruns. No nosso caso, aplicaremos No índice.
Marque 'Em todas as páginas', que funcionará.
Re: Como adicionar opções moderativas no Chatbox?
Eu já tinha colocado em todas as paginas não funcionou, marquei só portal também não funcionou.
Re: Como adicionar opções moderativas no Chatbox?
Olá!
Troque o iframe que lhe passei por esse:
Troque o iframe que lhe passei por esse:
- Código:
<div class="panel"><div class="inner"><span class="corners-top"><span></span></span><div id="chatbox_top" style="overflow:none;height:300px;"><object data="/chatbox/index.forum?page=front&" id="frame_chatbox" scrolling="yes" width="100%" height="100%" type="text/html"></object></div><script type="text/javascript">insertChatBoxNew('chatbox_top', '/chatbox/index.forum?page=front&');</script><img src="http://2img.net/i/fa/resize.gif" onmousedown="javascript:resizeElement(event, 'chatbox_top');" alt="" style="cursor:se-resize; float: right;"><div class="clear"></div><span class="corners-bottom"><span></span></span></div></div>
Re: Como adicionar opções moderativas no Chatbox?
Questão marcada como Resolvida ou o Autor solicitou que ela fosse arquivada. Tópico marcado como Resolvido e movido para Questões resolvidas. |
Fórum dos Fóruns :: Ajuda e atendimento ao utilizador :: Questões sobre códigos :: Questões resolvidas sobre códigos Javascript e jQuery
Página 1 de 1
Permissões neste sub-fórum
Não podes responder a tópicos