# Read data from "http://www.celestrak.com/NORAD/elements/stations.txt"

**URL:** https://forum.kirupa.com/t/read-data-from-http-www-celestrak-com-norad-elements-stations-txt/637465
**Category:** Uncategorized
**Created:** [November 16, 2017, 1:05pm UTC](https://forum.kirupa.com/t/read-data-from-http-www-celestrak-com-norad-elements-stations-txt/637465 "2017-11-16T13:05:12Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Powersoft](https://avatars.discourse-cdn.com/v4/letter/p/7ba0ec/32.png) [@Powersoft](https://forum.kirupa.com/u/Powersoft)
#### Post date: [November 16, 2017, 1:05pm UTC](https://forum.kirupa.com/t/read-data-from-http-www-celestrak-com-norad-elements-stations-txt/637465/1 "2017-11-16T13:05:12Z")

</div>

Hello,

I need some help.

I need to read the data from the url “[http://www.celestrak.com/NORAD/elements/stations.txt](http://www.celestrak.com/NORAD/elements/stations.txt)”

Have tried to fellow the sample on “Making HTTP Requests in JavaScript”

A part of the file “stations.txt” looks like:

ISS (ZARYA)  
1 25544U 98067A 17320.25760845 .00002780 00000-0 49193-4 0 9997  
2 25544 51.6424 0.2290 0004339 120.9517 357.7535 15.54152007 85403  
TIANGONG 1  
1 37820U 11053A 17320.11055913 .00062943 97032-5 19309-3 0 9993  
2 37820 42.7557 342.6253 0017793 85.7508 19.0465 15.91412673352067  
AGGIESAT 4  
1 41313U 98067HP 17319.44091328 .00076726 00000-0 29758-3 0 9996  
2 41313 51.6359 300.6730 0005003 48.0078 312.1352 15.86473153102820

But until now with no result.  
Please can you help me with this topic.  
Thanks for any help.

---

<div class="post-metadata">

### Author: ![kirupa](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/kirupa/32/11616_2.png) [@kirupa](https://forum.kirupa.com/u/kirupa)
#### Post date: [November 17, 2017, 10:51pm UTC](https://forum.kirupa.com/t/read-data-from-http-www-celestrak-com-norad-elements-stations-txt/637465/2 "2017-11-17T22:51:02Z")

</div>

Are you just trying to load the contents? Can you post the code you are currently using?

🙂

---

<div class="post-metadata">

### Author: ![Powersoft](https://avatars.discourse-cdn.com/v4/letter/p/7ba0ec/32.png) [@Powersoft](https://forum.kirupa.com/u/Powersoft)
#### Post date: [November 18, 2017, 9:09am UTC](https://forum.kirupa.com/t/read-data-from-http-www-celestrak-com-norad-elements-stations-txt/637465/3 "2017-11-18T09:09:58Z")

</div>

On this moment I have no code written in Javascript.  
Have done this in Java as a test. ( and other languages)  
For my furder program in principle i need only the first tree lines of the file, and store them in l1,l2 and l3 (variable)

Then i can proceed. Later I will it uses in NSBasic (Javascript)

Cheers, Jan

---

<div class="post-metadata">

### Author: ![Powersoft](https://avatars.discourse-cdn.com/v4/letter/p/7ba0ec/32.png) [@Powersoft](https://forum.kirupa.com/u/Powersoft)
#### Post date: [November 18, 2017, 10:25am UTC](https://forum.kirupa.com/t/read-data-from-http-www-celestrak-com-norad-elements-stations-txt/637465/4 "2017-11-18T10:25:29Z")

</div>

This is my code so far.

 ReadFromStations.txt document.writeln("Read TLE data ISS"); var xhr = new XMLHttpRequest(); xhr.open('GET',"http://www.celestrak.com/NORAD/elements/stations.txt",false); xhr.send();

```
    xhr.onreadystatechange = ProcessRequest;
    
    function processRequest(e){
        document.writeln("responce");
        document.writeln(xhr.readyState);
    }

</script>

```
