D
D
Dartess2014-04-14 18:18:14
JavaScript
Dartess, 2014-04-14 18:18:14

Is it possible to load a page via js?

I want to write an extension for chrome, which in the background would monitor changes on a certain site and would display a notification in case of some changes (for example, the appearance of news).
No server side - pure JavaScript. Is it really possible to download an html file from someone else's server using purely JS? Or is it fiction, security and all that? I do not want to start a server for the sake of a simple application "for myself".

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Deerenaros, 2014-04-14
@Dartess

$.load
PS Have a conscience sometimes .

F
frees2, 2014-04-14
@frees2

1 you need to check the headers, analogue in php - print_r
2 when the header changes - update the page with the above methods from commentators

P
Pavel Volintsev, 2014-04-14
@copist

I want to write a chrome extension that would monitor changes on a certain site in the background and would display a notification in case of some changes

The author is not talking about any site, but about a certain one. You need to return the 'Access-Control-Allow-Origin' header on that site with permission for all domains and AJAX requests will be executed.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question