I'm new to web programming. I'm going to the point. I have an api: link this is created in azure with asp.net which returns me a JSON or so I think and I try to consume it with this code.
<!DOCTYPE html>
<html lang="es">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>
<body>
<ul></ul>
<script src="js/jquery.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function() {
$.ajax({
type: "GET",
url: "http://apielviracom20170717104733.azurewebsites.net/api/Menus",
dataType: "json",
success: function(data) {
$("ul").children().remove();
$(data).find("MenuCompleto").each( function() {
var info = '<li>Fecha: ' + $(this).find("FechaString").text() + '</li>';
$("ul").append(info);
});
}
});
});
</script>
</body>
</html>
I do not understand why it does not work, Postman is perfect, I have read several post to consume the api and I think it is correct. any help I would appreciate it very much.
Thank you, best regards