franxico (franxico) wrote in bezilla,

Haiku 404

Hi guys,

I'd like to change the usual error message, replacing it with a random haiku, like in NetPositive. What do you think?

I tried some things, but I don't have knowledge enough to make it work properly. The page opens, but nothing is seen.

I found out how to modify that page here.

Then I adapted a JavaScript that I found. Here's the code (sorry, but I can't attach the files):

//netError.xhtml file

<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="">
<head> <title>Page cannot be reached</title>
<script src="haiku.js"></script>
<link rel="stylesheet" href="chrome://global/content/customerror.css" type="text/css" media="all" /> </head>

<!-- All body content STARTS HERE! -->
<script LANGUAGE = "JavaScript">
// this you put into you html doc where you want your quotes to appear
<!-- All body content ENDS HERE -->


// haiku.js file

// JavaScript Document
function makeArray(len) {
for (var i = 0; i < len; i++) this[i] = null;
this.length = len;

// you add as many quotes as you want here just make sure to change the makeArray(number)

haiku = new makeArray(38);
haiku[0] = "The web site you seek\u
Lies beyond our perception\u
But others await.",

haiku[1] = "Sites you are seeking\n
From your path they are fleeing\n
Their winter has come.",

haiku[2] = "A truth found, be told\n
You are far from the fold, Go\n
Come back yet again.",

haiku[3] = "Wind catches lily\n
Scatt'ring petals to the wind:\n
Your site is not found.",

haiku[4] = "These three are certain:\n
Death, taxes, and site not found.\n
You, victim of one.",

haiku[5] = "Ephemeral site.\n
I am the Blue Screen of Death.\n
No one hears your screams.",

haiku[6] = "Aborted effort:\n
The site, passed this veil of tears.\n
You ask way too much.",

haiku[7] = "Morning and sorrow\n
404 not with us now\n
Lost to paradise.",

haiku[8] = "Not a pretty sight\n
When the web dies screaming loud\n
The site is not found.",

haiku[9] = "Site slips through fingers\n
Pulse pounding hard and frantic\n
Vanishing like mist.",

haiku[10] = "The dream is shattered\n
The web site cannot be found\n
Inside the spring rain.",

haiku[11] = "Bartender yells loud\n
Your site cannot be found, boy\n
Buy another drink.",

haiku[12] = "Chrome megaphone barks\n
It's not possible to talk\n
Not yet anyway.",

haiku[13] = "Emptyness of soul\n
Forever aching blackness:\n
" not found."",

haiku[14] = "Click exciting link\n
Gossamer threads hold you back\n
404 not found.",

haiku[15] = "With searching comes loss\n
And the presence of absence:\n
The site is not found.",

haiku[16] = "You step in the stream,\n
But the water has moved on\n
The site is not here.",

haiku[17] = "Rather than a beep\n
Or a rude error message,\n
These words: 'Site not found.'",

haiku[18] = "Something you entered\n
Transcended parameters.\n
The site is unknown.",

haiku[19] = "Stay the patient course\n
Of little worth is your ire\n
The server is down",

haiku[20] = "There is a chasm\n
Of carbon and silicon\n
The server can't bridge.",

haiku[21] = "Chaos reigns within.\n
Reflect, repent, and retry.\n
Server shall return.",

haiku[22] = "Won't you please observe\n
A brief moment of silence\n
For the dead server?",

haiku[23] = "First snow, then silence.\n
This expensive server dies\n
So beautifully.",

haiku[24] = "Seeing my great fault\n
Through darkening dead servers\n
I begin again.",

haiku[25] = "Visit the home page\n
It can't be done easily\n
When the site is down.",

haiku[26] = "Cables have been cut\n
Southwest of Northeast somewhere\n
We are not amused.",

haiku[27] = "Site is silent, yes\n
No voices can be heard now\n
The cows roll their eyes.",

haiku[28] = "Silicon shudders\n
The site is down for the count\n
One big knockout punch.",

haiku[29] = "Yesterday it worked\n
Today it is not working\n
The web is like that.",

haiku[30] = "Errors have occurred.\n
We won't tell you where or why.\n
Lazy programmers.",

haiku[31] = "The code was willing\n
It considered your request,\n
But the chips were weak.",

haiku[32] = "Error reduces\n
Your expensive computer\n
To a simple stone.",

haiku[33] = "The ten thousand things\n
How long do any persist?\n
The file, not there.",

haiku[34] = "A file that big?\n
It might be very useful\n
But now it is gone.",

haiku[35] = "Server's poor response\n
Not quick enough for browser.\n
Timed out, plum blossom.",

haiku[36] = "To have no errors\n
Would be life without meaning\n
No struggle, no joy",

haiku[37] = "Login incorrect.\n
Only perfect spellers may\n
Enter this system."

// The random number generator.
function rand(n) {
seed = (0x015a4e35 * seed) % 0x7fffffff;
return (seed >> 16) % n;
var now = new Date()
var seed = now.getTime() % 0xffffffff



  • (no subject)


  • to keep alive

    according new LJ rules

  • Fork

    If anyone who helped with the port is interested we have a real fork. If you want to contribute your old patches we never got to CVS, contact me.…

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your IP address will be recorded