﻿

function DocNameExtract()
{
	var wholeurl = window.location.href;
	var x = wholeurl.length;
	while((wholeurl.substring(x,x-1)) != "."){ x--; } clipend = x;
	while((wholeurl.substring(x,x-1)) != "/"){ x--; } clipstart = x;
	return wholeurl.substring(clipend-1,clipstart);
}

function DocFileNameExtract()
{
	var wholeurl = window.location.href;
	var x = wholeurl.length;
	while((wholeurl.substring(x,x-1)) != "/"){ x--; } clipstart = x;
	return wholeurl.substring(wholeurl.length,clipstart);
}