Web Page Reader and Writer

Discussion in 'JavaScript' started by keioGirl, Jan 14, 2008.

  1. #1
    I would like to get some web pages before i start browsing it in the browser and make some modification to that webpage and then write to the browser using javascript. It's like Webpage filter or something like that. Is it possible? If then, which function I have to use to retrieve that page and then to rewrite.
    Please tell me!!
     
    keioGirl, Jan 14, 2008 IP
  2. MMJ

    MMJ Guest

    Messages:
    460
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Could you rephrase that?
     
    MMJ, Jan 14, 2008 IP
  3. keioGirl

    keioGirl Peon

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I mean....
    When the user try to open a web page, I would like to get that webpage to make some modifications before it is shown in the browser. (Just like web filter or adblock extension used in firefox or something like that.) And I would like to make it using Javascript.So, I want to know which function I have to use to get that webpage and send it back .(from and to the proxy server)

    If my statements still make you confuse, just let me know. :)
     
    keioGirl, Jan 14, 2008 IP
  4. MMJ

    MMJ Guest

    Messages:
    460
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #4
    JS modifies the "cached" page, nothing else. When you modify a document with JS you are not modifying the actual file.

    Past this into the address bar:
    javascript:document.body.innerHTML=''; void(0);
    Code (markup):
    Than hit enter.
     
    MMJ, Jan 14, 2008 IP