function AdminArticleEditPageOnSubmit( oF ) {
	if (oF.article_category_id.value=="") {
		alert( aJSLangDefs.articles_No_article_category_defined );
		oF.article_category_id.focus();
		return false;
	}
	if (oF.article_name.value=="") {
		alert( aJSLangDefs.articles_No_article_name_defined );
		oF.article_name.focus();
		return false;
	}
	return true;
}

function AdminArticlePreview( uid ) {
	window.opener.open( '/article.php?article_id='+uid , 'article_preview_'+uid );
}

function AdminArticleConnecteds( uid ) {
	document.location.href='connecteds.php?uid='+uid;
}

function AdminArticleApply( uid ) {
	var d = {
		inajax : 1,
		ajaxevent : "apply",
		article_id : uid
	};
	// FIXME
	d.larticle_1_larticle_title = document.frm_article_edit.larticle_1_larticle_title.value;
	d.larticle_1_larticle_body = CKEDITOR.instances.larticle_1_larticle_body.getData();
	d.larticle_2_larticle_title = document.frm_article_edit.larticle_2_larticle_title.value;
	d.larticle_2_larticle_body = CKEDITOR.instances.larticle_2_larticle_body.getData();
	d.larticle_3_larticle_title = document.frm_article_edit.larticle_3_larticle_title.value;
	d.larticle_3_larticle_body = CKEDITOR.instances.larticle_3_larticle_body.getData();

	$.ajax(
		{
			type: "POST",
			cache: false,
			data: d,
			success: function( retval ) {
				eval( retval );
			}
		}
	);
}
