function checkCaptionFields() {
	var chatupline = $('#getyounoticed_').val();	
	var description = $('#description_').val();
	var error = "";
	
	if ( chatupline.length < 21 )
	{
		error += "Tagline must be at least 20 characters\n";
	}
	if ( description.length < 21 )
	{
		error += "Description must be at least 20 characters";
	}
	
	if ( error == "" )
	{
		return true;
	}
	else
	{
		alert(error);
		return false;
	}
}

function checkDetailedInformation(sex, subid) {
	var error = "";
	
	if ( $("input[name='haircol_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Hair colour\n";
	}
	if ( $("input[name='eyecol_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Eye colour\n";	
	}
	if ( $("input[name='build_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Body type\n";
	}
	if ( $("input[name='height_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Height\n";
	}
	if ( $("input[name='race_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Ethnicity\n";
	}
	if ( $("input[name='religion_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Religion\n";
	}
	if ( $("input[name='education_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Education\n";
	}
	if ( $("input[name='employment_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Employment\n";
	}
	if ( $("input[name='income_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Income\n";
	}
	if ( $("input[name='drinker_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Drinking\n";
	}
	if ( $("input[name='smoker_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Smoking\n";
	}
	if ( $("input[name='familystatus_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Relationships\n";
	}
	if ( $("input[name='children_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Have children\n";
	}
	if ( $("input[name='want_children_[" + sex + "][" + subid + "]']:checked").val() == 0 )
	{
		error += "Please tell us about your Want children\n";
	}
	
	if ( error == "" )
	{
		return true;
	}
	else
	{
		alert(error);
		return false;
	}
}

function qf_tag() {
	var rsi_segs = [];
	var segs_beg=document.cookie.indexOf('rsi_segs=');
	if(segs_beg>=0){
	segs_beg=document.cookie.indexOf('=',segs_beg)+1;
	if(segs_beg>0){
	var segs_end=document.cookie.indexOf(';',segs_beg);
	if(segs_end==-1)segs_end=document.cookie.length;
	rsi_segs=document.cookie.substring(segs_beg,segs_end).split('|');
	}}
	var segQS = rsi_segs.length> 0 ? ";rsi=" + rsi_segs[0] +";" : "";
	for (var i = 1; i <rsi_segs.length && i <20; i++)
	segQS += ("rsi" + "=" + rsi_segs[i] + ";");
}