Hacker News new | past | comments | ask | show | jobs | submit login
Ask HN: What Technology does Optimizely use?
15 points by dawie on Dec 5, 2010 | hide | past | favorite | 9 comments
I was playing with Optimizely's experiment creator today and I really want to know how they grab any website and then allow the user to interact with it.

I want to do something similar, but instead of editing the code, I want to allow the user to select a region of the page and take a screenshot of it.

If someone can comment on how they do that, I would really appreciate it.




There's a proxy that attaches JS to a frame. It needs to be proxied to bypass the same origin js limitations. Another way you could take would be to make a browser extension.

I used a similar technique in http://wikify.antimatter15.com/server/proxy?http://optimizel...

source code: http://code.google.com/p/wikify/source/browse/trunk/appengin...


How can I contact you? You can also drop me an email at tabtrickapp at google's email service


It's not possible to take a screenshot with unprivledged javascript (there's a method to draw a window into a canvas for privledge js in firefox and a screenshot api for chrome and safari). The only way would be to use a browser extension unless you wanted to use implement your own rendering engine (perhaps based on getComputedStyle) in canvas (that would be cool though!).


After a quick glance, they load the page in an iFrame and inject their CSS + JS into it.

Any of changes you make will be "compiled" into a JS file which you then include on your page. Whatever edits you made will only be reflected client side on load.

Generating a screenshot is a completely different process than editing a website so I'm not sure Optimizely's tech is that useful to you.




Check out "wkhtmltopdf", I think it has a library to take a screenshot.


I am more interested in getting an existing website to display inside my own, than doing screenshots. There are services and APIs out there that does screenshots quite well.


Building a browser extension wold probably make the most sense for taking a screenshot of a full page or portion of it.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: