// JavaScript Document function rdEventos_includes() { if (typeof(jQuery) == 'undefined') rdEventos_includeLibreria('https://ruralesdata.com/js/jquery-1.11.1.min.js','js',function(){jQuery.noConflict();}); } function rdEventos_includeLibreria(ruta,tipo,callbackFunc){ var head = document.getElementsByTagName('head')[0]; if(tipo=='js') { var se1 = document.createElement('script'); se1.src = ruta; if(callbackFunc!=null) se1.onload=callbackFunc; head.appendChild(se1); } if(tipo=='css') { var cssNode_jquery = document.createElement('link'); cssNode_jquery.type = 'text/css'; cssNode_jquery.rel = 'stylesheet'; cssNode_jquery.href = ruta; cssNode_jquery.media = 'screen'; head.appendChild(cssNode_jquery); } } function rdEventos_next(num) { rdEventos_includeLibreria('https://ruralesdata.com/api/eventos/next.css','css',null); document.write("
"); jQuery.ajax( "https://ruralesdata.com/api/eventos/next.php", { type: 'POST', data : {num:num, lg:'es', id:'67'}} ) .done(function(html) { jQuery('#rdEventos').html(html); }) .fail(function() { jQuery('#rdEventos').html("Error cargando datos"); }) } function rdEventos_list() { rdEventos_includeLibreria('https://ruralesdata.com/api/eventos/list.css','css',null); document.write("
"); jQuery.ajax( "https://ruralesdata.com/api/eventos/list.php", { type: 'POST', data : { lg:'es', id:'67'}} ) .done(function(html) { jQuery('#rdEventos').html(html); }) .fail(function() { jQuery('#rdEventos').html("Error cargando datos"); }) } rdEventos_includes(); rdEventos_list();