// layout2.js
// Cross-Browser.com & SitePoint.com - Equal Column Height Demo (2 Column)

if (document.getElementById || document.all) { // minimum dhtml support required
  document.write("<"+"style type='text/css'>#footer{visibility:hidden;}<"+"/style>");
  xAddEventListener(window, 'load', winOnLoad, false);
}
function winOnLoad()
{
  var ele = xGetElementById('leftColumn');
  if (ele && xDef(ele.style, ele.offsetHeight)) { // another compatibility check
    adjustLayout();
    xAddEventListener(window, 'resize', winOnResize, false);
  }
}
function winOnResize()
{
  adjustLayout();
}
function adjustLayout()
{
  // Get content heights
  var cHeight = xHeight('centerColumnContent');
  var lHeight = xHeight('leftColumnContent');

  // Find the maximum height
  var maxHeight = Math.max(lHeight, cHeight);

  // Assign maximum height to all columns
  xHeight('leftColumn', maxHeight);
  xHeight('centerColumn', maxHeight);

  // Show the footer
  xGetElementById('footer').style.visibility = 'visible';
}

 



function verifyEditMainNovelFields(){
	//Check title length
	if(document.edit_main_novel.title.value.length < 1){
        alert("You must fill in a title.");
        return false;
        }
}


function getQuerystrings(inputId) {

		var urlString = document.location.href;
		var queryString = urlString.substring(urlString.indexOf('?'),urlString.length);
		
		/*test
		alert(urlString+"\n"+queryString);
		
		inputObj = document.getElementById(inputId);
		inputObj.value = queryString;
		
		//test
		alert(document.getElementById(inputId).value); */
		
	
	}


  

