extensions/prototype -- string, array & encryption helpers

Loading extensions/prototype adds hashing, Base64/hex, HTML/URL escaping and AES/TEA methods to every string, unique() / shuffle() / min() / max() to every array, and exports ext.fn.getRandId(). Type in the boxes -- every value is recomputed live; the buttons re-run the random helpers.

String helpers (live)
.sha1() .sha256() .md5() .base64encode() .base64decode() .toHex() .fromHex() .toHtmlSimple() .toHtml() .encodeURI() .decodeURI()

Each decode row is applied to the encoded value above it and turns green when the text comes back. toHex() is byte oriented: Latin-1 and 2-byte UTF-8 characters (e.g. Cyrillic) round-trip via fromHex().utf8decode(), but emoji / CJK characters are written as raw UTF-16 code units and come back different (paste one to see the marker turn red).

encryptAes / decryptAes, encryptTea / decryptTea (live)
.encryptAes(key) .decryptAes(key) .encryptTea(key) .decryptTea(key)

AES-CTR (128 bit) uses a random nonce, so the ciphertext changes on every call while decryptAes() always returns the text; TEA is deterministic. Both ciphertexts are Base64.

Array helpers (live)
parsed .unique() .min() .max() .shuffle()

Numeric items are parsed as numbers, anything else stays a string; min()/max() compare with < / >.

ext.fn.getRandId()
getRandId() getRandId('user_') getRandId('id_', true) getRandId(true)
Self test (known answers)
waiting for the module...