Having recently started using cryptography in my application, I find myself puzzled by the relationship between the input text length and the ciphertext it results in. Befor
From my understanding, in block modes (cbc, ecb) output length will be rounded to the block size, as returned by mcrypt_enc_get_block_size. Plus, you need to store IV along with the data, so the size will be rounded strlen(data) + mcrypt_enc_get_iv_size().
As for the base64 encoding, I wouldn't bother (but make sure to use hex encoding when dumping your db).