Status
Not open for further replies.
I've been working on cleaning up some of my sites code, both from an SEO standpoint and from a page load standpoint.

Although I selected this as a "How Do I" prefix, I would also like to make this a request for future versions. It would be nice for pages that don't display the chat box to not include the CSS think pages that don't display the css and scripting for the shoutbox.

I have added IF THIS_SCRIPT to the CSS templates to remove them from displaying on every page. However, I have this code which appears to be empty css displaying in my header, how do I get remove it?
Code:
.formcontrols .blockrow .dbtech_shouts .dbtech_vbshout_tabs.alt {
}

.formcontrols .blockrow .dbtech_shouts .dbtech_vbshout_tabs.alt2 {
}

.formcontrols .blockrow .dbtech_shouts .dbtech_vbshout_window .dbtech_vbshout_frame {
}

.formcontrols .blockrow .dbtech_shouts .dbtech_vbshout_highlight {
}

Also all this script is at the bottom of every page, and I would like to also remove it:

Code:
<script type="text/javascript">
					<!--
					vbphrase['dbtech_vbshout_idle'] = "Idle..."
					vbphrase['dbtech_vbshout_flagged_idle'] = "You are currently flagged as Idle. Click <a href=\"javascript://\" onclick=\"%link%\">here</a> to un-flag."
					vbphrase['dbtech_vbshout_saving_shout'] = "Saving shout..."
					vbphrase['dbtech_vbshout_editing_shout'] = "<span style=\"font-weight:bold;\">Editing</span> a shout. Press <span style=\"font-weight:bold;\">ESC</span> to cancel editing."
					vbphrase['dbtech_vbshout_editing_sticky'] = "Editing sticky note..."
					vbphrase['dbtech_vbshout_deleting_shout'] = "Deleting shout..."
					vbphrase['dbtech_vbshout_fetching_shouts'] = "Fetching shouts..."
					vbphrase['dbtech_vbshout_fetching_shouts_in_x_seconds'] = "Fetching shouts in %seconds% seconds..."
					vbphrase['dbtech_vbshout_no_active_users'] = "There are currently no users chatting."
					vbphrase['dbtech_vbshout_saving_shout_styles'] = "Saving Shout Styles..."
					vbphrase['dbtech_vbshout_ajax_disabled'] = "Either your browser does not support AJAX, or the forum administrator has chosen to disable AJAX. vBShout cannot run under these conditions."
					vbphrase['dbtech_vbshout_must_wait_x_seconds'] = "You must wait at least %time% seconds between shouts. It has been %time2% seconds since your last shout."
					vbphrase['dbtech_vbshout_are_you_sure_banunban'] = "Are you sure you wish to ban / unban this user?"
					vbphrase['dbtech_vbshout_are_you_sure_silenceunsilence'] = "Are you sure you wish to silence / unsilence this user?"
					vbphrase['dbtech_vbshout_are_you_sure_ignoreunignore'] = "Are you sure you wish to ignore / unignore this user?"
					vbphrase['dbtech_vbshout_are_you_sure_pruneshouts'] = "Are you sure you wish to prune all shouts from this user?"
					vbphrase['dbtech_vbshout_are_you_sure_chatremove'] = "Are you sure you wish to remove this user from this Chat Room?"
					vbphrase['dbtech_vbshout_are_you_sure_chatjoin'] = "Do you want to join the Chat Room: %roomname%? You were invited by %username%."
					vbphrase['dbtech_vbshout_are_you_sure_chatleave'] = "Are you sure you wish to leave this chat room?"
					vbphrase['dbtech_vbshout_are_you_sure_shoutdelete'] = "Are you sure you wish to delete this shout?"
					vbphrase['dbtech_vbshout_everyone'] = "Everyone"
					
					var editorOptions = {"1":{"italic":"0","underline":"0","color":"Sienna","size":"13px"}};
					var instanceOptions = {"1":{"enableshoutsound":"0","enableinvitesound":"0","enablepmsound":"0","logging":"0","editors":"494","notices":"67","optimisation":"1","allowsmilies":"1","activeusers":"0","sounds":"0","enablemenu":"1","altshouts":"1","enableaccess":"1","maxshouts":"20","maxarchiveshouts":"500","height":"150","floodchecktime":"0","maxchars":"0","maximages":"4","idletimeout":"720","refresh":"5","maxchats":"3","shoutorder":"DESC","maxsize":"3","postping_interval":"100","threadping_interval":"50","memberping_interval":"50","shoutboxtabs":"5","logging_deep":"0","logging_deep_system":"0","enablepms":"1","enablepmnotifs":"1","enable_sysmsg":"1","sounds_idle":"0","avatars_normal":"0","avatar_width_normal":"15","avatar_height_normal":"15","avatars_full":"1","avatar_width_full":"22","avatar_height_full":"22","maxshouts_detached":"50","height_detached":"1100","refresh_idle":"0","archive_numtopshouters":"10","autodelete":"72","minposts":"0","timeformat":"h:i A","shoutarea":"above","archive_link":"0","blogping_interval":"50","shoutping_interval":"10000","aptlping_interval":"50","tagping_interval":"50","mentionping_interval":"50","quoteping_interval":"50","quizmadeping_interval":"50","quiztakenping_interval":"50"}};
					var instancePermissions = {"1":{"canviewshoutbox":"1","canviewarchive":"1","canshout":"1","caneditown":"1","caneditothers":"1","canprune":"1","cansticky":"1","canban":"1","cansearcharchive":"1","autoidle":"1","cancreatechat":"1","isprotected":"1","canmodchat":"1","enablemenu":"1","showaction":"1","cansilence":"1","canpm":"1","ismanager":"2"}};
					var bbcodePermissions = {"1":{"bit":"7263","array":{"allow_bbcode_basic":"1","allow_bbcode_color":"1","allow_bbcode_size":"1","allow_bbcode_font":"1","allow_bbcode_align":"1","allow_bbcode_list":"","allow_bbcode_link":"1","allow_bbcode_code":"","allow_bbcode_php":"","allow_bbcode_html":"","allow_bbcode_img":"1","allow_bbcode_quote":"1","allow_bbcode_custom":"1"}}};
					var userOptions = {"enable_pms":"1","enable_notifs":"1","enable_sysmsg":"1","enable_override":"0","shoutsounds":"1","invitesounds":"0","pmsounds":"0","hidealtcolours":"0","hideavatars":"0","enable_detach":"1","enable_clear":"1","enable_smilies":"1","enable_bold":"1","enable_italic":"0","enable_underline":"0","enable_font":"1","enable_color":"1","enable_size":"1","is_detached":"0","pmtime":"1334112580","soundSettings":{"1":{"shouts":"1","each":"0","eachSlice":"0","all":"0","any":"0","collect":"0","detect":"0","findAll":"0","grep":"0","include":"0","inGroupsOf":"0","inject":"0","invoke":"0","max":"0","min":"0","partition":"0","pluck":"0","reject":"0","sortBy":"0","toArray":"0","zip":"0","size":"0","inspect":"0","map":"0","find":"0","select":"0","filter":"0","member":"0","entries":"0","every":"0","some":"0","_reverse":"0","_each":"0","clear":"0","first":"0","last":"0","compact":"0","flatten":"0","without":"0","reverse":"0","reduce":"0","uniq":"0","intersect":"0","clone":"0","toJSON":"0","chatroom_26_":"1","chatroom_28_":"1"},"2":{"shouts":"0"}},"archive":"","vbversion":"3","idle":{"1":{"unIdle":"","unPause":""}}};
					var templates = {"shout":"<div class=\"dbtech_vbshout_shout%altclass%\" name=\"dbtech_vbshout_shoutwrapper\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\"%hidenewshout%>\r\n\t<input name=\"dbtech_vbshout_shout_raw\" type=\"hidden\" value=\"%message_raw%\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\" />\r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit%>%time%</span> \r\n\t<span data-instanceid=\"%instanceid%\">%memberaction_dropdown%:</span> \r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit% style=\"%styleprops%\">%message%</span>\r\n</div>","pm":"<div class=\"dbtech_vbshout_shout%altclass%\" name=\"dbtech_vbshout_shoutwrapper\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\"%hidenewshout%>\r\n\t<input name=\"dbtech_vbshout_shout_raw\" type=\"hidden\" value=\"%message_raw%\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\" />\r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit%>%time%</span> \r\n\t<span data-instanceid=\"%instanceid%\">[<span style=\"font-weight:bold;\">to %pmuser%</span>] %memberaction_dropdown%:</span> \r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit% style=\"%styleprops%\">%message%</span>\r\n</div>","me":"<div class=\"dbtech_vbshout_shout%altclass%\" name=\"dbtech_vbshout_shoutwrapper\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\"%hidenewshout%>\r\n\t<input name=\"dbtech_vbshout_shout_raw\" type=\"hidden\" value=\"%message_raw%\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\" /> \r\n\t*<span data-instanceid=\"%instanceid%\">%memberaction_dropdown%</span> \r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit% style=\"%styleprops%\">%message%</span>*\r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit%>%time%</span>\r\n</div>","system":"<div class=\"dbtech_vbshout_shout%altclass%\" name=\"dbtech_vbshout_shoutwrapper\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\"%hidenewshout%>\r\n\t<input name=\"dbtech_vbshout_shout_raw\" type=\"hidden\" value=\"%message_raw%\" data-instanceid=\"%instanceid%\" data-shoutid=\"%shoutid%\" />\r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit% style=\"font-weight:bold;\">%time%</span> \r\n\t<span name=\"dbtech_vbshout_shout_username\" data-instanceid=\"%instanceid%\" style=\"font-style:italic;\">%musername%:</span> \r\n\t<span name=\"dbtech_vbshout_shout\" data-instanceid=\"%instanceid%\"%canedit% style=\"font-style:italic;\">%message%</span>\r\n</div>"};
					var tabs = {"1":{"shoutreports":{"text":"Unhandled Reports: <span name=\"dbtech_vbshout_shoutreports\" data-instanceid=\"1\">0</span>","canclose":"0","extraparams":{"loadurl":"vbshout.php?do=reportlist&instanceid=1"}},"shoutnotifs":{"text":"Notifications","canclose":"0"},"usertags_1_":{"text":"User Tags","canclose":"0"},"chatroom_50_1":{"text":"jim","canclose":"1","extraparams":{"chatroomid":"50"}}}};
			
					// -->
				</script>
 
In order to support autoloading on every page, what you're asking is sadly not possible :(

The amount of support requests we received for how to correctly configure shoutbox to load on other pages was immense, so we had to change it.
 
Status
Not open for further replies.

Legacy vBShout

vBulletin 3.8.x vBulletin 4.x.x
Seller
DragonByte Technologies
Release date
Last update
Total downloads
3,175
Customer rating
5.00 star(s) 1 ratings
Back
Top