PageSourceSearch

https://inkbunny.net/js82/header.js

js inkbunny.net collected 2026-09-24 08:28:59 UTC 5,006 bytes, 91 lines download raw bytes

1//Init JWplayer key value if required.
2if ($('jwplayer-key')) jwplayer.key=$('jwplayer-key').getValue();
3
4//Time of day cycle for backgrounds that use it.
5var skoo = $('celestial-skoo').getValue();
6var daytime_start = $('celestial-daytime_start').getValue();
7var dusk_start = $('celestial-dusk_start').getValue();
8var night_start = $('celestial-night_start').getValue();
9var dawn_start = $('celestial-dawn_start').getValue();
10var nolocation = $('celestial-nolocation').getValue();
11var stopmachinations = $('celestial-stopmachinations').getValue();
12
13//Actions to perform after page load.
14addEvent(window, 'load', function () {
15
16	//Prefetch using JS DOM after page load.
17	var prefetchLinks = $$('input.prefetch-link');
18	prefetchLinks.each(function(s) {
19		var prefetchLink = s.getValue();
20		var l = document.createElement('LINK');
21		l.setAttribute('rel', 'prefetch');
22		l.setAttribute('href', prefetchLink);
23		document.getElementsByTagName('html')[0].appendChild(l);
24	});
25});
26
27//Matomo site usage and stats tracking. Used to be called Piwik.
28var _paq = window._paq || [];
29
30function piwikActions()
31{
32	_paq.push(["setCustomVariable", 1, /* Index, the number from 1 to 5 where this Custom Variable name is stored */
33		"LoginStatus", /* The name of the variable */
34		$('piwik-logintype').getValue(), /* Value, for example: "member", "guest" */
35		"visit" /* Scope of the Custom Variable, "visit" means the Custom Variable applies to the current visit, "page" means just the current page. */
36	]);
37	_paq.push(["trackPageView"]);
38	_paq.push(["enableLinkTracking"]);
39
40  (function() {
41    var u = $('piwik-dir').getValue();
42    _paq.push(["setTrackerUrl", u + "/matomo.php"]);
43	_paq.push(["setSiteId", "1"]);
44    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
45    g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'/matomo.js'; s.parentNode.insertBefore(g,s);
46  })();
47}
48
49//Other vars needed by scripts.
50var global_token = $('general-global_token').getValue();
51var thumb_size = $('general-thumb_size').getValue();
52var submissionsviewall_wide = $('general-submissionsviewall_wide').getValue();
53var flash_newitems = $('general-flash_newitems').getValue()  == "true" ? true : false;
54var show_newnotice_numbers = $('general-show_newnotice_numbers').getValue() == "true" ? true : false;
55//Check if this browser supports HTML5 storage object.
56var supports_storage = (typeof(Storage)!=="undefined") && ('localStorage' in window) && (window.localStorage!==null);
57var global_timeofday = $('general-global_timeofday').getValue();
58var original_timeofday = global_timeofday;	
59var global_bgtheme = $('general-global_bgtheme').getValue();
60var bgtheme_image_sizes = $('general-bgtheme_image_sizes').getValue();
61var incrementview = $('general-incrementview').getValue() == 'true' ? true : false;
62
63//Always empty local storage for guests. This ensures the storage is reset and ready for a new logged in session.
64if ($('general-clearstorage').getValue() == 'yes')
65{
66	if (supports_storage) {
67		localStorage.clear();
68	}
69}
70
71//If user is logged in and this browser supports HTML5 storage, then run regular AJAX requests to get latest site notice and user notice data.
72if ($('general-loggedin').getValue() == 'yes' && supports_storage) {
73	//Set default cookie values. These are updated regularly via AJAX polling later.
74	//We let new tabs/windows loaded set these each time as we assume this is the latest data.
75	localStorage["site_status_maintmode"] = $('sitestatus-panicmodeStatus').getValue();
76	localStorage["site_status_notice_on"] = $('sitestatus-site_notice_on').getValue();
77	localStorage["site_status_dismiss"] = $('sitestatus-site_notice_hide').getValue();
78	localStorage["site_status_time_on"] = $('sitestatus-timer_on').getValue();
79	
80	//For the following, if the value passed is string "false" then set the value to a boolean false.
81	localStorage["site_status_notice_text_bbcode_parsed"] = $('sitestatus-notice_text_bbcode_parsed').getValue();
82	if (localStorage["site_status_notice_text_bbcode_parsed"] == "false") localStorage["site_status_notice_text_bbcode_parsed"] = false;
83	localStorage["site_status_event_datetime_system"] = $('sitestatus-event_datetime_system').getValue();
84	if (localStorage["site_status_event_datetime_system"] == "false") localStorage["site_status_event_datetime_system"] = false;
85	localStorage["site_status_event_datetime_epoch"] = $('sitestatus-event_datetime_epoch').getValue();
86	if (localStorage["site_status_event_datetime_epoch"] == "false") localStorage["site_status_event_datetime_epoch"] = false;
87	
88	//Begin site status polling at regular intervals (interval is in milliseconds). All tabs/windows share cookie data filled by the polling.
89	//So no matter how many tabs/windows are open, there will only be ONE poll request to the server via AJAX per INTERVAL time (milliseconds).
90	site_notice_checkmessage_init($('sitestatus-checkintervalMS').getValue() * 1);
91}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.