Skip to content

Instantly share code, notes, and snippets.

@josuebasurto
Created May 16, 2014 15:26
Show Gist options
  • Select an option

  • Save josuebasurto/0b96fb895ed112f49b29 to your computer and use it in GitHub Desktop.

Select an option

Save josuebasurto/0b96fb895ed112f49b29 to your computer and use it in GitHub Desktop.
Script para poder saber los dias de antiguedad de un Portal en Ingress
var fecha = portal_capture_details.textContent.split(' ')[1]
var dt = new Date(fecha.substring(8,12),fecha.substring(0,2)-1,fecha.substring(4,6))
Math.round(Math.abs(((new Date()).getTime() - dt.getTime())/(oneDay)));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment