PageSourceSearch

https://www.parksville.ca/js/fontsize.js

js parksville.ca collected 2026-09-24 09:42:04 UTC 2,180 bytes, 74 lines download raw bytes

1function fontSwitch(styletitle) 
2{
3	
4	var imgbutton = document.getElementById('fontsize_graphic');
5	for(i=0; (a = document.getElementsByTagName("link")[i]); i++) 
6	{
7		if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title")) 
8		{
9			a.disabled = true;
10			if(a.getAttribute("title") == styletitle) 
11			{ 
12				a.disabled = false; 
13				//Set Graphic
14				//alert(styletitle);
15				switch(styletitle) 
16				{
17					case "largefont":
18						imgbutton.src="/vimages/tbtn_textsize_decrease.png";
19						imgbutton.onclick = function() { fontSwitch('regularfont'); }
20						imgbutton.alt = "Decrease Text Size";
21					break;
22					case "regularfont":
23						imgbutton.src="/vimages/tbtn_textsize_increase.png";
24						imgbutton.onclick = function() { fontSwitch('largefont'); }
25						imgbutton.alt = "Increase Text Size";
26					break;
27					default:
28						imgbutton.src="/vimages/tbtn_textsize_increase.png";
29						imgbutton.onclick = null;
30					break;
31				}
32			}
33		}
34	}
35};
36
37
38function getPreferredStyleSheet() {
39  var i, a;
40  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) 
41  {
42    if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("rel").indexOf("alt") == -1 && a.getAttribute("title")) return a.getAttribute("title");
43  }
44  return null;
45};
46
47function getActiveStyleSheet() {
48  var i, a;
49  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
50    if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title") && !a.disabled) return a.getAttribute("title");
51  }
52  return null;
53};
54
55function createCookie(name,value,days) {
56  if (days) {
57    var date = new Date();
58    date.setTime(date.getTime()+(days*24*60*60*1000));
59    var expires = "; expires="+date.toGMTString();
60  }
61  else expires = "";
62  document.cookie = name+"="+value+expires+"; path=/";
63};
64
65function readCookie(name) {
66  var nameEQ = name + "=";
67  var ca = document.cookie.split(';');
68  for(var i=0;i < ca.length;i++) {
69    var c = ca[i];
70    while (c.charAt(0)==' ') c = c.substring(1,c.length);
71    if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
72  }
73  return null;
74};

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.