#!/usr/bin/perl use strict; use warnings; use CGI; use CGI qw( :standard ); use CGI::Carp qw( fatalsToBrowser set_message ); use CGI::Ajax; my $cgi = new CGI ( ); my $pjx = new CGI::Ajax ( 'fetch_content' => \&get_rot13_html, 'fetch_js' => \&get_decoding_js, 'fetch_fetcher' => \&get_fetcher_code ); print ( $pjx->build_html( $cgi, \&default_html) ); sub get_rot13_html { my $html = < obql { onpxtebhaq:#000006; pbybe:#ssssnn; } Guvf vf n dhvrg grn ebbz. Gurer'f n cbepu bhgfvqr jurer lbh pna frr gur onl. Gur pevpxrgf naq gur svfuvat obngf pernx. V qba'g rire jnag gb yrnir. nyreg("zru"); THEHTML ; # #
# # artwork # #

# This is a quiet tea room. #

# There's a porch outside where you can see the bay. #

# The crickets and the fishing boats creak. #

# # I don't ever want to leave. #

# return ( $html ); } sub get_decoding_js { my $javascript = <='A' && b<='Z') || (b>='a' && b<='z') ? Rot13.map[b] : b); } return s; }, init: function() { if (Rot13.map != null) return; var map = new Array(); var s = "abcdefghijklmnopqrstuvwxyz"; for (i=0; i='N' && o<='M') || (o>='n' && o<='m') ? Ebg13.znc[o] : o); } erghea f; }, vavg: shapgvba() { vs (Ebg13.znc != ahyy) erghea; ine znc = arj Neenl(); ine f = "nopqrstuvwxyzabcdefghijklm"; sbe (v=0; v Behold the power of WEB TWO POINT OH!
loading, man.

Dynamically loading javascript which dynamically loads rot13'd javascript, which is decoded and then dynamically loads rot13'd html, decodes it and inserts it into the document FTW.

It's not useless, it's enabling a secure enterprise web service archtecture over modern ajax and xml technologies using sophisticated encryption algorithms to protect confidential data.

Fun fact: This actually validates.

Source

HTML ; return ( $html ); }