Writing a local XML file from a parsed URL?? Similar to RSS

Discussion in 'Javascript' started by linearfusion, Jun 27, 2006.

  1. linearfusion

    linearfusion Guest

    Hello,

    I may not have worded the subject correctly, but what I am trying to do
    is pull the XML data from the following stream,
    http://www.360voice.com/api/blog-getentries.asp?tag=changeagent&num=5,
    into a webpage. What I would like to do, or think I need to do is
    create a webpage that will pull the XML data from the above URL and
    write it to a local XML file. I would then like to apply an XSL
    stylesheet to the local XML file and display it on a website. In other
    words, I am trying to pull the above URL into my website.... so I am
    looking for a place to start with javascript. This is almost like
    displaying RSS feeds into a webpage.

    Thanks so much!!!!!
    Shannon
     
    linearfusion, Jun 27, 2006
    #1
    1. Advertisements

  2. linearfusion

    Jeremy Guest

    linearfusion wrote:
    > Hello,
    >
    > I may not have worded the subject correctly, but what I am trying to do
    > is pull the XML data from the following stream,
    > http://www.360voice.com/api/blog-getentries.asp?tag=changeagent&num=5,
    > into a webpage. What I would like to do, or think I need to do is
    > create a webpage that will pull the XML data from the above URL and
    > write it to a local XML file. I would then like to apply an XSL
    > stylesheet to the local XML file and display it on a website. In other
    > words, I am trying to pull the above URL into my website.... so I am
    > looking for a place to start with javascript. This is almost like
    > displaying RSS feeds into a webpage.
    >
    > Thanks so much!!!!!
    > Shannon
    >


    Shannon,
    I'm afraid you're barking up the wrong tree with Javascript. This is
    something you need to do server-side; for example, using PHP or a
    similar back-end language.

    Due to security restrictions on Javascript, it's not possible to
    (directly) grab a file from a server besides your own. You could have a
    backend script that grabs a remote file and spits it back out, and then
    use javascript to access the remote feed through that backend script.
    Then, you could use XSLT (for example: AjaXSLT, a Google library) to
    transform the feed.

    But this is probably best accomplished through a backend script. Ask in
    a PHP group - you can do what you want to do in about 8 lines of code
    with PHP.

    Jeremy
     
    Jeremy, Jun 27, 2006
    #2
    1. Advertisements

  3. linearfusion

    linearfusion Guest

    Awesome!! Thanks for the help!!

    Jeremy wrote:
    > linearfusion wrote:
    > > Hello,
    > >
    > > I may not have worded the subject correctly, but what I am trying to do
    > > is pull the XML data from the following stream,
    > > http://www.360voice.com/api/blog-getentries.asp?tag=changeagent&num=5,
    > > into a webpage. What I would like to do, or think I need to do is
    > > create a webpage that will pull the XML data from the above URL and
    > > write it to a local XML file. I would then like to apply an XSL
    > > stylesheet to the local XML file and display it on a website. In other
    > > words, I am trying to pull the above URL into my website.... so I am
    > > looking for a place to start with javascript. This is almost like
    > > displaying RSS feeds into a webpage.
    > >
    > > Thanks so much!!!!!
    > > Shannon
    > >

    >
    > Shannon,
    > I'm afraid you're barking up the wrong tree with Javascript. This is
    > something you need to do server-side; for example, using PHP or a
    > similar back-end language.
    >
    > Due to security restrictions on Javascript, it's not possible to
    > (directly) grab a file from a server besides your own. You could have a
    > backend script that grabs a remote file and spits it back out, and then
    > use javascript to access the remote feed through that backend script.
    > Then, you could use XSLT (for example: AjaXSLT, a Google library) to
    > transform the feed.
    >
    > But this is probably best accomplished through a backend script. Ask in
    > a PHP group - you can do what you want to do in about 8 lines of code
    > with PHP.
    >
    > Jeremy
     
    linearfusion, Jun 27, 2006
    #3
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. HNguyen
    Replies:
    4
    Views:
    2,692
    HNguyen
    Dec 21, 2004
  2. Katrin Tomanek

    Java and huge XML file to be parsed

    Katrin Tomanek, Jun 17, 2004, in forum: Java
    Replies:
    47
    Views:
    2,352
    Dale King
    Apr 15, 2006
  3. YuliaG
    Replies:
    2
    Views:
    638
    Arnaud Berger
    Apr 4, 2005
  4. Lyndon
    Replies:
    1
    Views:
    691
    Leonard Blaisdell
    Jul 25, 2005
  5. Christopher Boomer
    Replies:
    0
    Views:
    495
    Christopher Boomer
    Jul 28, 2003
  6. Jonathan Groll
    Replies:
    1
    Views:
    570
    Kouhei Sutou
    Jun 27, 2009
  7. Erik Wasser
    Replies:
    5
    Views:
    864
    Peter J. Holzer
    Mar 5, 2006
  8. Pam
    Replies:
    2
    Views:
    191
Loading...