

// This configuration file is used to demonstrate how to add checkboxes to your tree.
// If your site will not display checkboxes, pick a different configuration file as 
// the example to follow and adapt.

// Notes:
// If you are going to set USEICONS = 1, then you will want to edit the gif files and 
// remove the white space on the right


// Auxiliary functions for the contruction of the tree
// You will mcertainly want to change these functions for your own purposes

// If you want to add checkboxes to the folder you will have to create a function 
// similar to this one to do that and call it below in the tree construction section

// These functions are directly related with the additional JavaScript in the 
// page holding the tree (demoCheckbox.html), where the form handling code
// resides
function generateCheckBox(parentfolderObject, itemLabel, checkBoxDOMId, checkBoxValue,URL,isChecked) {
	var newObj;

	// Read the online documentation for an explanation of insDoc and gLnk,
    // they are the base of the simplest Treeview trees
	newObj = insDoc(parentfolderObject, gLnk("B", itemLabel, URL))

    // The trick to show checkboxes in a tree that was made to display links is to 
	// use the prependHTML. There are general instructions about this member
    // in the online documentation
	if (isChecked)
	{
		newObj.prependHTML = "<td valign=middle><input type=checkbox name="+checkBoxDOMId+" id="+checkBoxDOMId+" value="+checkBoxValue+" checked></td>"
	}
	else
		newObj.prependHTML = "<td valign=middle><input type=checkbox name="+checkBoxDOMId+" id="+checkBoxDOMId+" value="+checkBoxValue+"></td>"

}

