Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Dec 2005
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question How to send the source of current page?

    Hi!

    Is it possible to send the source of the current page loaded (that the sctipt is on) to, say.. a php script via POST method?

    What I was originally wanting to do was see if there was a way to "grep" a specific part out of the loaded page and send that value, but I think that would be too much of a pain for me to figure out and may be easier if I can just send the whole source and deal with it there.


    Thanks!

  • #2
    jkd
    jkd is offline
    Senior Coder jkd's Avatar
    Join Date
    May 2002
    Location
    metro DC
    Posts
    3,163
    Thanks
    1
    Thanked 18 Times in 18 Posts
    var source = (typeof window.XMLSerializer == "undefined")? document.documentElement.outerHTML : (new XMLSerializer()).serializeToString(document);

    // now send source variable via ajax


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •