JS reference THIS page not a URL

I am trying to reference the body copy output page from a quiz module.
I can successfully return the entry (parent) page - which in our case is a registration form, but I want the result set that's output/presented as a new page (ie: Thank you body copy)



I've tried these:



+escape(location.href) and other variations: document.location window.location and so on…



any suggestions?



Do I need to append the URL with something?



Thanks

Can you explain in better details what you are trying to do? Are you pulling in a quiz page with ajax?

If you do want to show a results page you'll most likely need to pass in the relevant variables.


Sorry guys, reading back, it was a bit vague.



My users will take a quiz and receive a printable certificate if they pass.

I can't use the email reply WYSIWYG window within the details screen to acheive what I need to offer the participants, so I've elected to use the Thank You bodycopy.



I can't write a client side PDF converter, so I'm using an external service that gets called if the user has reached an acceptable score - that part all works fine.



Problem is, the service retrieves the parent page, not the generated Thank you body copy which is where I will format the certificate with user details, etc.


    
    if ((userScore/quizScore)<=0.8)
      {
      document.write("Congratulations %user_details_current_user%, you have achieved a score of %quiz_total_points% blal bla bla ");
     
    
    void(window.open('http://www.web2pdfconvert.com/convert.aspx?cURL='+escape(window.location.href)+'&outputmode=stream'+'&title='+escape(document.title)));
      
      }
    else { blal bla bla......
    


I hope this makes more sense now! Thanks

Oh, please ignore the backwards if condition (flipped around for testing so I didnt have to fill the form out)