function slugomatic(fromInput, toInput)
{
	text = $(fromInput).value;
	text = text.replace(/^\s+|\s+$/g, '').replace(/[^\w ]/g,'').replace(/ +/g,'-').substr(0, 50);
	$(toInput).value = text.toLowerCase();
}  