if (!window.jqsDCCRnC)
    jqsDCCRnC = jQuery.noConflict();

function CheckAndCreateCookie(userid, paramComObjId, uniqueKey, rating)
{
	
	 var AnonyKey='';
	//checking if user is anonymous
	if(userid==-1)
	{
		var cookieName='AnonyKey_' + paramComObjId;
		var key='key_' + uniqueKey ;//+ '_' + rating;
		//check if cookie exists
		var cookieVal = jqsDCCRnC.cookie(cookieName);
		if(cookieVal!=null)
		{
			//cookie found
			AnonyKey=cookieVal;
			return AnonyKey;
		}
		else
		{
		    //cookie not  found
		    jqsDCCRnC.cookie(cookieName, key, { expires: 365, path: '/', secure: false });

			AnonyKey=key;
			return AnonyKey;
		}
	}
	
}


