<?php
	$key = 'Tool Get Link Download NhacCuaTui.Com';
	$mkey = 'Tìm nhạc và lấy link tải mp3 nhaccuatui , Tải nhạc 320kbs, lossness miễn phí cho mobile, Lấy link , download   mp3 nhaccuatui.';
	include '../../template/header.php';
?>

	<div class="col-right-xs">
		<div class="mainblok">
			<div class="phdr">
					<div vocab="https://schema.org/" typeof="BreadcrumbList">
						<span property="itemListElement" typeof="ListItem">
							<a href="/"  property="item" typeof="WebPage">
								<i class="fa fa-home"></i> <span property="name">Home</span>
							</a>
							<meta property="position" content="1">
						</span>
						<i class="fa fa-angle-right"></i>
						<span property="itemListElement" typeof="ListItem">
							<a href="/getlink/"  property="item" typeof="WebPage">
								<i class="fa fa-chain-broken"></i> <span property="name">GetLink</span>
							</a>
							<meta property="position" content="2">
						</span>
						<i class="fa fa-angle-right"></i>
						<span property="itemListElement" typeof="ListItem">
							<span property="name">Tool Get Link NhacCuaTui.Com</span>
							<meta property="position" content="3">
						</span>
					</div>
			</div>
			<div class="newsx">Tool GetLink nhạc mp3 Lossless, 320Kbs Trên NhacCuaTui. Getlink playlist nhạc, tải nhạc chuông từ Nhaccuatui.Com. Tải video full HD từ NhacCuaTui Video.</div>
			<div class="menu">
				<strong>Link hỗ trợ:</strong><br />
				https://www.nhaccuatui.com/bai-hat/canh-ba-nguyen-tran-trung-quan.p3aqNv7HHkbD.html<br />
				https://www.nhaccuatui.com/playlist/duyen-het-roi-phan-ai-so-kiep-choi-voi-va.yOKkv9wNDsL7.html<br />
				https://www.nhaccuatui.com/video/hay-trao-cho-anh-son-tung-m-tp-ft-snoop-dogg-ft-madison-beer.cSyv5ozS1BPFA.html<br />
				<form role="form" class="form-horizontal" id="form" method="post" onSubmit="return false;">
					<input type="text" name="link" id="link" placeholder="http://www.nhaccuatui.com/bai-hat/yeu-la-tha-thu-em-chua-18-ost-onlyc.vmjlLAAxhof5.html">
					<input type="submit" id="submit" value="Lấy link get" name="submit" />
				</form>
			</div>
			<div id="DownloadLink"></div>
			<div id="listLink"><div class="newsx" style="text-align:center"><input type="button" name="getnhac" id="getnhac" value="Lấy danh sách nhạc hot"/></div></div>
		</div>
		
<?php require '../list.php'; ?>
	</div>
	<div class="col-left-xs">
<?php require '../../tools/toolslist.php'; ?>
	</div>
	<div class="clear"></div>

<script>
$(document).ready(function(){
	$("#submit").click(function(){
		$("#submit").addClass('disabled');
		$("#DownloadLink").hide().html('<div class="gmenu" style="text-align: center;"><img src="/template/images/loading.svg" /></div>').slideDown('slow');
		getlink();
	});
	$('#getnhac').click(function(){
		$("#submit").addClass('disabled');
		$("#listLink").hide().html('<div class="gmenu" style="text-align: center;"><img src="/template/images/loading.svg" /></div>').slideDown('slow');
		$.ajax({
			url : 'api.php?hotsong',
			type : 'get',
			dataType : 'json',
			success : function (result){
				$('#link').val(result.success);
				getlink();
				$("#listLink").slideUp();
			},
			error: function() 
			{
				$("#listLink").hide().html('<div class="gmenu" style="text-align: center;"><i style="color:red">Có lỗi hệ thống, vui lòng kiểm tra lại!</i></div>').slideDown('slow');
			}
		});
	});
});
	function getlink() {
		var form = $('#form')[0];
		var formData = new FormData(form);
		$.ajax({
			url: "api.php",
			type: "POST",
			data:  formData,
			contentType: false,
			cache: false,
			processData:false,
			success: function(rs)
			{
				res = JSON.parse(rs);
				if(res.success){
					$("#submit").removeClass('disabled');
					$("#DownloadLink").hide().html(res.success).slideDown('slow');
				}
				if(res.error){
					$("#submit").removeClass('disabled');
					$("#DownloadLink").hide().html('<div class="gmenu" style="text-align: center;"><i style="color:red">'+res.error+'</i></div>').slideDown('slow');
				}
			},
			error: function() 
			{
				$("#DownloadLink").hide().html('<div class="gmenu" style="text-align: center;"><i style="color:red">Có lỗi hệ thống, vui lòng kiểm tra lại!</i></div>').slideDown('slow');
			}
		});
		$("#link").attr("placeholder", $("#link").val()).val("");
	}
</script>
<script async src="https://cdn.jwplayer.com/libraries/rlx7bqvD.js"></script>
<?php
	require '../../template/footer.php';
?>

