diff --git a/agenda.js b/agenda.js new file mode 100644 index 0000000..c91c142 --- /dev/null +++ b/agenda.js @@ -0,0 +1,56 @@ +class Agenda{ + + constructor(){ + this.url = "http://ergast.com/api/f1/current"; + this.last_api_call = null; + this.las_api_result = null; + } + + cargarDatos(){ + $.ajax({ + dataType: "xml", + url: this.url, + method: 'GET', + success: function(datos){ + //$("h5").text((new XMLSerializer()).serializeToString(datos)); + + //Presentación de los datos contenidos en XML + $('Race',datos).each(function(item){ + var stringDatos = "