function ajaxUploadKtp()
	{
		$("#loading")
		.ajaxStart(function(){
			$(this).show();
		})
		.ajaxComplete(function(){
			$(this).hide();
		});

		$.ajaxFileUpload
		(
			{
				url:'KtpUpload.php',
				secureuri:false,
				fileElementId:'fileToUpload1',
				dataType: 'json',
				success: function (data, status)
				{
					if(typeof(data.error) != 'undefined')
					{
						if(data.error != '')
						{
							document.getElementById("msg1").innerHTML = data.error;
							//alert("y1");
						}else
						{
							document.getElementById("msg1").innerHTML = " File Name: "+ data.msg;
							document.getElementById("gambar1").value = data.msg;
							
						}
					}
				},
				error: function (data, status, e)
				{
					document.getElementById("msg1").innerHTML = e;
					//alert("y");
				}
			}
		)
		
		return false;

	}
	
function ajaxUploadKK()
	{
		$("#loading")
		.ajaxStart(function(){
			$(this).show();
		})
		.ajaxComplete(function(){
			$(this).hide();
		});

		$.ajaxFileUpload
		(
			{
				url:'KKUpload.php',
				secureuri:false,
				fileElementId:'fileToUpload2',
				dataType: 'json',
				success: function (data, status)
				{
					if(typeof(data.error) != 'undefined')
					{
						if(data.error != '')
						{
							document.getElementById("msg2").innerHTML = data.error;
							//alert("y1");
						}else
						{
							document.getElementById("msg2").innerHTML = " File Name: "+ data.msg;
							document.getElementById("gambar2").value = data.msg;
							
						}
					}
				},
				error: function (data, status, e)
				{
					document.getElementById("msg2").innerHTML = e;
					//alert("y");
				}
			}
		)
		
		return false;

	}
	
function ajaxUploadAgunan1()
	{
		$("#loading")
		.ajaxStart(function(){
			$(this).show();
		})
		.ajaxComplete(function(){
			$(this).hide();
		});

		$.ajaxFileUpload
		(
			{
				url:'Agunan1Upload.php',
				secureuri:false,
				fileElementId:'fileToUpload3',
				dataType: 'json',
				success: function (data, status)
				{
					if(typeof(data.error) != 'undefined')
					{
						if(data.error != '')
						{
							document.getElementById("msg3").innerHTML = data.error;
							//alert("y1");
						}else
						{
							document.getElementById("msg3").innerHTML = " File Name: "+ data.msg;
							document.getElementById("gambar3").value = data.msg;
							
						}
					}
				},
				error: function (data, status, e)
				{
					document.getElementById("msg3").innerHTML = e;
					//alert("y");
				}
			}
		)
		
		return false;

	}
	
function ajaxUploadAgunan2()
	{
		$("#loading")
		.ajaxStart(function(){
			$(this).show();
		})
		.ajaxComplete(function(){
			$(this).hide();
		});

		$.ajaxFileUpload
		(
			{
				url:'Agunan2Upload.php',
				secureuri:false,
				fileElementId:'fileToUpload4',
				dataType: 'json',
				success: function (data, status)
				{
					if(typeof(data.error) != 'undefined')
					{
						if(data.error != '')
						{
							document.getElementById("msg4").innerHTML = data.error;
							//alert("y1");
						}else
						{
							document.getElementById("msg4").innerHTML = " File Name: "+ data.msg;
							document.getElementById("gambar4").value = data.msg;
							
						}
					}
				},
				error: function (data, status, e)
				{
					document.getElementById("msg4").innerHTML = e;
					//alert("y");
				}
			}
		)
		
		return false;

	}
	
