Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.7 > vBulletin 3.7 Template Modifications

Reply
 
Thread Tools
Add notice on shoubox[Updates] Details »»
Add notice on shoubox[Updates]
Version: 1.00, by vietdjclub vietdjclub is offline
Developer Last Online: Jan 2012 Show Printable Version Email this Page

Category: Miscellaneous Hacks - Version: 3.7.0 Beta 3 Rating:
Released: 01-16-2008 Last Update: 01-17-2008 Installs: 15
Uses Plugins Template Edits
 
No support by the author.

this mod will add 2 notice on your shoutbox

Install Instructions

step 1
Go to your admin Control Panel => Plugin System => Manage Products => [Add/Import Product];
Click Browse and find product-thongbao_shoutbox.xml
Click Import

step 2

OPEN forumhome_vbshout

THEN CLEAR ALL AND REPLACE ALL WITH THIS CODE

Code:
<form action="vbshout.php?{$session['sessionurl']}" method="post" name="vbshoutform" onsubmit="return postShout(this)">
<input type='hidden' name='do' value='shout' />
<input type='hidden' name='color' />
<input type='hidden' name='fontFamily' />
<input type='hidden' name='fontWeight' />
<input type='hidden' name='textDecoration' />
<input type='hidden' name='fontStyle' />

<div id='shout_emo' style='display:none'>
		<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
		<tr>
			<td class="tcat" align="center">
				Emoticons
			</td>
		</tr>
		<tr>
			<td class='alt2' width='100%' height='100%' align='center' valign='top'>
				$Smilie_Build
			</td>
		</tr>
		</table>
	<br />
</div>
		<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
		<thead>
		<tr>
			<td class="tcat" align="center">
				<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_vbshout')"><img id="collapseimg_forumhome_vbshout" src="$stylevar[imgdir_button]/collapse_tcat$vbcollapse[collapseimg_vbshout].gif" alt="" border="0" /></a>
				<a href='vbshout.php?{$session['sessionurl_q']}do=archive'>Khu Chat Chit [y?u cầu viết tiếng việt c? dấu]</a>
			</td>
		</tr>
		</thead>
		<tbody id="collapseobj_forumhome_vbshout" style="$vbcollapse[collapseobj_forumhome_vbshout]">
			<tr>
				<td class="alt1" align="left" width="100%">
				<if condition="!$vboptions[shout_editor_position]">
					<if condition="$bbuserinfo[userid] > 0">
					<table width='100%' border='0' cellpadding='0' cellspacing='0'>
						<tr>
						<td width='100%'>
							<input type="text" name="shout" style="width: 90%" class="bginput" />
						</td>
						<td style='white-space:nowrap' width='1%'>
							<input type="submit" value="Shout" class="button" />
							<if condition="$vboptions[shout_extra_options]">
							<input type='button' class='button' value='Clear' onclick='sb_Clear()' />
							<input type='button' class='button' value='Smilies' onclick='sb_Smilies(this)' />
							<input id='sb_mem_bold' type='button' class='button' style='font-weight:bold' value='B' onclick='sb_PropChange_Button(this, "fontWeight")' />
							<input id='sb_mem_underline' type='button' class='button' style='text-decoration:underline' value='U' onclick='sb_PropChange_Button(this, "textDecoration")' />
							<input id='sb_mem_italic' type='button' class='button' style='font-style:italic' value='I' onclick='sb_PropChange_Button(this, "fontStyle")' />
							<select id='sb_color_mem' name='font_color' onchange='sb_PropChange(this, "color")'>
								{$DropDowns['color_selector']}
							</select>
							<select id='sb_font_mem' name='font_selector' onchange='sb_PropChange(this, "fontFamily")'>
								{$DropDowns['font_selector']}
							</select>
							</if>
						</td>
					</tr>
					</table>
					<div style="height: 2px"></div>
					</if>
				</if>
<!-- Start Th?ng b?o by Vietdjclub -->
<if condition="$vboptions[Shout_box_Notice_enabled] == 1">
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
<td align="center"><a href="$vboptions[bburl]/showthread.php?$session[sessionurl]t=$vboptions[First_Thread_Id]">
<img src="$vboptions[Show_Notice_Icon]" border="0"/><b>$vboptions[First_Thread_Title]</b></a></td>
<td align="center"><a href="$vboptions[bburl]/showthread.php?$session[sessionurl]t=$vboptions[Second_Thread_Id]"><img src="$vboptions[Show_Notice_Icon]" border="0"/><b>$vboptions[Second_Thread_Title]</b></a></td>
</tr>
</table>
</if>
<!-- /End Th?ng B?o by Vietdjclub -->

					<div id="vbshout" style="overflow:auto;height:{$vboptions['shout_box_height']}px;width:100%;">
						Đang tải,Vui l?ng chờ...
					</div>



				<if condition="$vboptions[shout_editor_position]">
					<if condition="$bbuserinfo[userid] > 0">
					<div style="height: 2px"></div>
					<table width='100%' border='0' cellpadding='0' cellspacing='0'>
					<tr>
						<td width='100%'>
							<input type="text" name="shout" style="width: 90%" class="bginput" />
						</td>
						<td style='white-space:nowrap' width='1%'>
							<input type="submit" value="Shout" class="button" />
							<if condition="$vboptions[shout_extra_options]">
							<input type='button' class='button' value='Clear' onclick='sb_Clear()' />
							<input type='button' class='button' value='Smilies' onclick='sb_Smilies(this)' />
							<input id='sb_mem_bold' type='button' class='button' style='font-weight:bold' value='B' onclick='sb_PropChange_Button(this, "fontWeight")' />
							<input id='sb_mem_underline' type='button' class='button' style='text-decoration:underline' value='U' onclick='sb_PropChange_Button(this, "textDecoration")' />
							<input id='sb_mem_italic' type='button' class='button' style='font-style:italic' value='I' onclick='sb_PropChange_Button(this, "fontStyle")' />
							<select id='sb_color_mem' name='font_color' onchange='sb_PropChange(this, "color")'>
								{$DropDowns['color_selector']}
							</select>
							<select id='sb_font_mem' name='font_selector' onchange='sb_PropChange(this, "fontFamily")'>
								{$DropDowns['font_selector']}
							</select>
							</if>
						</td>
					</tr>
					</table>
					</if>
				</if>
				</td>
			</tr>
		</tbody>
		</table>


</form>
<br />

<script type='text/javascript'>
<!--

postingShout = false

function requestShouts()
{
	if (!postingShout)
	{
		ShoutRequest = new vB_AJAX_Handler(true)
		ShoutRequest.onreadystatechange(showShouts)
		ShoutRequest.send('vbshout.php', 'nocache=' + (5 * Math.random() * 1.33) )
	}
}

function showShouts()
{
	if (ShoutRequest)
	{
		if (ShoutRequest.handler.readyState == 4 && ShoutRequest.handler.status == 200 && ShoutRequest.handler.responseText)
		{
			Shouts           = fetch_object('vbshout')
			Shouts.innerHTML = '<table cellpadding="1" cellspacing="3" border="0" width="95%" align="left">' + ShoutRequest.handler.responseText + '</table>'
			setTimeout('requestShouts()', 10000)
			<if condition="$vboptions[shout_messages_order]">
			document.getElementById('vbshout').scrollTop = 99999;
			</if>
		}
	}
}

function sb_CollectHV(sbForm)
{
	rString = ''
	inputObjs = sbForm.getElementsByTagName('input')
	for (i = 0; i < inputObjs.length; i++)
	{
		if (inputObjs[i].type == 'hidden' && inputObjs[i].value != '')
		{
			rString += '&' + inputObjs[i].name + '=' + PHP.urlencode(inputObjs[i].value)
		}
	}

	return rString
}

function postShout(formObj)
{
	doShout = new vB_AJAX_Handler(true)
	doShout.onreadystatechange(postedShout)

	if (postingShout)
	{
		alert('Posting in progress..')
		return false
	}

	Shout = formObj.shout.value

	if (Shout.replace(/ /g, '') == '')
	{
		alert('You must enter a shout!')
		return false
	}

	doShout.send('vbshout.php', 'do=shout&shout=' + PHP.urlencode(Shout) + sb_CollectHV(document.forms['vbshoutform']))
	sb_Clear()
	postingShout = true

	return false
}

function postedShout()
{
	if (doShout.handler.readyState == 4 && doShout.handler.status == 200)
	{
		postingShout = false
		requestShouts()
	}
}

function sb_Input_SC(sProperty, setting)
{
	set_shout_memory_cookie('vbshout_' + sProperty, setting)
	eval('document.forms["vbshoutform"].shout.style.' + sProperty + ' = "' + setting + '"')
	eval('document.forms["vbshoutform"].' + sProperty + '.value = "' + setting + '"')
}

function getSelectionValue(eSelector)
{
	return eSelector.options[eSelector.options.selectedIndex].value == 'Default' ? '' : eSelector.options[eSelector.options.selectedIndex].value
}

function sb_PropChange(eSelector, sProperty)
{
	sb_Input_SC(sProperty, getSelectionValue(eSelector))
}

function sb_PropChange_Button_Value(sProperty)
{
	trueValue = ''
	switch (sProperty)
	{
		case 'fontWeight':
		falseValue = 'bold'
		break;

		case 'textDecoration':
		falseValue = 'underline'
		break;

		case 'fontStyle':
		falseValue = 'italic'
		break;
	}

	set_shout_memory_cookie('vbshout_' + sProperty, ((eval('document.forms["vbshoutform"].' + sProperty + '.value'))? trueValue : falseValue))

	return (eval('document.forms["vbshoutform"].' + sProperty + '.value'))? trueValue : falseValue
}

function sb_PropChange_Button(cButton, sProperty)
{
	if (cButton.value.match(/\*/))
	{
		cButton.value = cButton.value.replace(/\s+\*/, '')
	}
	else
	{
		cButton.value = cButton.value + ' *'
	}

	sb_Input_SC(sProperty, sb_PropChange_Button_Value(sProperty))
}

function sb_Smilie(code)
{
	document.forms["vbshoutform"].shout.value += ' ' + code
	return false
}

function sb_Clear()
{
	document.forms["vbshoutform"].shout.value = ''
	return true;
}

function sb_Smilies(cButton)
{
	if (cButton.value.match(/\*/))
	{
		cButton.value = cButton.value.replace(/\s+\*/, '')
	}
	else
	{
		cButton.value = cButton.value + ' *'
	}
	
	document.getElementById('shout_emo').style.display = (document.getElementById('shout_emo').style.display == 'none')? '' : 'none'
}

function set_shout_memory_cookie(name, value)
{
	expires = new Date();
	expires.setTime(expires.getTime() + (1000 * 86400 * 365));
	value = value.replace('#', '')

	if (value != '')
	{
		set_cookie(name, value.replace('#', ''), expires);
	}
	else
	{
		delete_cookie(name);
	}
}

function grab_memory_cookies()
{
	memory_font = fetch_cookie('vbshout_fontFamily')
	memory_color = fetch_cookie('vbshout_color')
	memory_bold = fetch_cookie('vbshout_fontWeight')
	memory_underline = fetch_cookie('vbshout_textDecoration')
	memory_italic = fetch_cookie('vbshout_fontStyle')

	if (memory_font != null && memory_font != '')
	{
		obj = fetch_object('sb_font_mem')

		for (i = 0; i < obj.options.length; i++)
		{
			if (obj.options[i].value == memory_font)
			{
				obj.options[i].selected = true
				sb_PropChange(obj, 'fontFamily')
			}
		}
	}

	if (memory_color != null && memory_color != '')
	{
		obj = fetch_object('sb_color_mem')

		for (i = 0; i < obj.options.length; i++)
		{
			if (obj.options[i].value == '#' + memory_color)
			{
				obj.options[i].selected = true
				sb_PropChange(obj, 'color')
			}
		}
	}

	if (memory_bold != null && memory_bold != '')
	{
		sb_PropChange_Button(fetch_object('sb_mem_bold'), "fontWeight")
	}

	if (memory_underline != null && memory_underline != '')
	{
		sb_PropChange_Button(fetch_object('sb_mem_underline'), "textDecoration")
	}

	if (memory_italic != null && memory_italic != '')
	{
		sb_PropChange_Button(fetch_object('sb_mem_italic'), "fontStyle")
	}
}

grab_memory_cookies()
requestShouts()

-->
</script>

step 3
Go to your admin Control Panel => vBulletin Options => vBulletin Options => Vietdjclub-Add Notice On Shoutbox => [Edit Settings]

all done

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 01-17-2008, 11:04 AM
SwollenCranium's Avatar
SwollenCranium SwollenCranium is offline
 
Join Date: Oct 2007
Location: Raleigh, NC
Posts: 263
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

<!-- Start Thông báo by Vietdjclub -->

???

I'll pass.
Reply With Quote
  #3  
Old 01-17-2008, 11:06 AM
Magnumutz's Avatar
Magnumutz Magnumutz is offline
 
Join Date: Feb 2006
Location: Romania
Posts: 731
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Dude... no offense but did you take a look at the vB Version: 3.5.0 RC2 of that mod?
C'mon, that's really outdated.
Reply With Quote
  #4  
Old 01-18-2008, 02:25 AM
vietdjclub vietdjclub is offline
 
Join Date: Oct 2007
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

just updated
Reply With Quote
  #5  
Old 01-18-2008, 03:15 AM
Magnumutz's Avatar
Magnumutz Magnumutz is offline
 
Join Date: Feb 2006
Location: Romania
Posts: 731
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Then post the link to the updated version.
Reply With Quote
  #6  
Old 01-18-2008, 05:30 AM
xixxon's Avatar
xixxon xixxon is offline
 
Join Date: Jun 2007
Location: Việt Nam.
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

how 'bout chatbox? i just installed the chatbox of Dream and wonder is it the same
Reply With Quote
  #7  
Old 06-25-2008, 07:15 PM
GraNdMaStEr-B GraNdMaStEr-B is offline
 
Join Date: Jun 2008
Location: JeRzEy Boi
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

where is OPEN forumhome_vbshout located?
Reply With Quote
  #8  
Old 06-26-2008, 04:14 AM
vietdjclub vietdjclub is offline
 
Join Date: Oct 2007
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by GraNdMaStEr-B View Post
where is OPEN forumhome_vbshout located?
on ForumHome Template
Reply With Quote
  #9  
Old 07-06-2008, 09:14 AM
honcho honcho is offline
 
Join Date: Apr 2007
Posts: 74
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

installed this but notice is not coming up ant ideas
update its all went pete tong and need to uninstall it but it wont go bk to how it was anyone got the

forumhome_vbshout

normal temp-late please so i can just get rid of this omg
Reply With Quote
  #10  
Old 08-09-2008, 02:40 PM
nhuhuu's Avatar
nhuhuu nhuhuu is offline
 
Join Date: Sep 2004
Posts: 45
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

cám ơn Bạn đã post bài này mình nghĩ nó hay
translate to English : " thanks for viet friend ...i like this mod"
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:17 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04396 seconds
  • Memory Usage 2,310KB
  • Queries Executed 23 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete