Created
August 17, 2015 20:42
-
-
Save akobashikawa/49a089cb0460137ee76d to your computer and use it in GitHub Desktop.
Obteniendo el tipo de cambio desde la web de "El peruano"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Tipo de Cambio</title> | |
</head> | |
<body> | |
<h1>Tipo de Cambio</h1> | |
<p id="result">Cargando...</p> | |
<p><small>Tomado de: http://www.elperuano.com.pe/edicion/</small></p> | |
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script> | |
<script> | |
$(document).on('ready', function() { | |
$.get('http://crossorigin.me/http://www.elperuano.com.pe/edicion/') | |
.then(function(data) { | |
var $html = $(data); | |
var result = $html.find('#clima .tex12normal').text(); | |
$('#result').html(result); | |
}); | |
}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment