Skip to content

Node js read http url content #533

Closed
@MKT123

Description

@MKT123

Hi...
I need to read external http url which has data (can be of any extension xml,txt,ics). for eg: I downloaded the basic.xml to local . instead i need to read the file directly from url (https). can someone tel me how to read the content from external url?
fs.readFile('./public/basic.xml', 'utf8', function(err, data) {
if (err) {
console.log(err);
} else {
console.log(data);

}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions