@Craig's note: base64_encode() is better suited for that. In fact, it produces smaller output and operates slightly faster. I did a little benchmark -- here are my findings:
File: JPG, 631614 bytes
== Base64 ==
execution time: 0.0039639472961426 secs
output length: 842152
== UUencode ==
execution time: 0.004105806350708 secs
output length: 870226