code: function(parent, text)
  	{
  		var doc = parent.ownerDocument;
  		var node = doc.createTextNode(text);
  		
  		if (parent != null)
  		{
  			parent.appendChild(node);
  		}
  		
  		return node;
  	}
docs: Function: write
  
  Creates a text node for the given string and appends it to the given
  parent. Returns the text node.
  
  Parameters:
  
  parent - DOM node to append the text node to.
  text - String representing the text to be added.