• EnglishSpanishGermanFrenchPolishChinese (Traditional)


EnglishSpanishGermanFrenchPolishChinese (Traditional)

Operating systems, scripting, PowerShell and security

Operating systems, software development, scripting, PowerShell tips, network and security

Menú principal
  • Categorías
  • Cursos
  • Libro de PowerShell
  • Lo mejor
  • Lo último
  • Proyectos
  • Contactar
Ir al contenido

Leer un archivo JSON con la programación Movistar+ en Node.js

JavaScript
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
var http = require('https');
 
var url = 'https://www.jesusninoc.com/s/movistar.php';
http.get(url, function(res) {
      var body = '';
      res.on('data', function(chunk) {
         body += chunk;
      });
      res.on('end', function() {
        var jsonData = JSON.parse(body)
        for (var i = 0; i < jsonData.length; ++i) {
          console.log(jsonData[i].Nombre);
          console.log(jsonData[i].Pases[0].Titulo);
          console.log("----------------------------------");
        }
      });
    }).on('error', function(e) {
      console.log("Error: " + e.message);
});

Publicado el día 22 de junio de 2018

CATEGORÍAS

JavaScript, Node.js

ETIQUETAS

data, Function, HTTP, HTTPS, Jesús Niño, Jesús Niño Camazón, JSON, Length, Log, Movistar, programación

MÁS

  • Crear un sistema con jQuery que permita almacenar en un fichero de un servidor la hora, longitud, latitud de cualquier dispositivo utilizando el GPS del navegador mediante una petición a un…
  • Crear una comunicación entre un cliente en PowerShell de Windows y un servidor en Node.js utilizando TCP/IP
  • Pedir el nombre de un proceso y mostrar información del proceso mediante PowerShell con Node-PowerShell, EJS (Embedded JavaScript), Body-parser y Express
  • Crear un sistema para ver rutinas de entrenamientos con información sobre el entrenamiento y dibujos (versión con Cards) (utilizando jQuery, Bootstrap, JSON)
  • Crear un sistema para ver rutinas de entrenamientos con información sobre el entrenamiento y dibujos (versión con Popovers) (utilizando jQuery, Bootstrap, JSON)
  • Listar procesos de PowerShell con Node-PowerShell (Node.JS) y mostrarlos en una web con Express