I'm trying to create a reverse proxy to work like http://www.meowbify.com/, It's a cool platform that replaces images with cats animations. I tried Apache and nginx "reverse proxy" just to reverse proxy one existing site, which worked ok with sites like www.bcc.co.uk but didn't work with edition.cnn.com/. (I was using the regular ReverseProxyPass in apache and proxy_pass in nginx). In apache I also used the proxy_html_module, in order to rewrite the links.
So how does http://www.meowbify.com/ works? I've searched the mobifiy site which states:
How it works: Mobify.js uses a technique called client side adaptation to remix HTML in the browser. The remixed content is interpreted by the browser as if the server had sent it in the first place!
The Mobify.js tag bootstraps the adaptation and loads the Mobify.js file, which performs it. The tag activates in iOS, Android and BlackBerry browsers. By default, the Mobify.js file is loaded from the development server.
The development server is part of the Mobify Client, a command line tool for building Mobify.js projects. It compiles the Mobify.js file dynamically per request. The file contains two parts, the Mobify.js API and site specific adaptations.
Adaptations are expressed as a series of operations on the source DOM, the DOM constructed from the page’s original HTML. HTML Elements can be selected, then rendered with a template. Finally, the rendered template is written to the browser.
To make the long story short, it uses some css magic in order to display the site adapted to each browser.
I guess that the trick of mewbifity is manipulation the site directories (i.e cat.'site'.meowbify.com/).
So how can I do something similar?
Thanks in advance, Guyl