PageSourceSearch

https://www.grow-it-organically.com/support-files/tswdomutils.js

js grow-it-organically.com collected 2026-09-24 22:31:52 UTC 1,663 bytes, 52 lines download raw bytes

1/* Copyright 2009-2010 Taco Software. All rights reserved.
2 * http://tacosw.com
3 *
4 * This file is part of the Component Library included in Taco HTML Edit.
5 * Licensed users of Taco HTML Edit may modify and use this source code 
6 * for their web development (including commercial projects), as long as 
7 * this copyright notice is retained.
8 *
9 * The contents of this file may not be published in a format intended
10 * for access by other humans, so you may not put code examples on a
11 * web site with all or part of the contents of this file, and you may
12 * not publish the contents of this file in a printed format.
13 */
14
15var TSWDomUtils = new Object; //object for static method calls
16
17//Returns an array of children of element with name tagName; as opposed to getElementsByTagName
18//which returns any descendant.
19TSWDomUtils.getChildrenWithTagName = function(element, tagName)
20{
21	tagName = tagName.toUpperCase();
22	var results = new Array();
23	var children = element.childNodes;
24	for(var i=0; i<children.length; i++)
25	{
26		var child = children[i];
27		if(child.tagName != null && child.tagName.toUpperCase() == tagName)
28		{
29			results.push(child);
30		}
31	}
32	return results;
33};
34
35//Get the first child of element with a particular class name.
36TSWDomUtils.getChildWithClassName = function(element, className)
37{
38	var children = element.childNodes;
39	for(var i=0; i<children.length; i++)
40	{
41		var child = children[i];
42		if(child.tagName != null && child.className == className)
43		{
44			return child;
45		}
46	}
47	return null;
48};
49
50/* The checksum below is for internal use by Taco HTML Edit, 
51   to detect if a component file has been modified.
52   TacoHTMLEditChecksum: BAE92AA0 */

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.