title: Encoding/Compressing a large integer into alphanumeric value
body: <p>I have a very large integer 12-14 digits long and I want to encrypt/compress this to an alphanumeric value so that the integer can be recovered later from the alphanumeric value. I tried to convert this integer using a 62 base and tried to map those values to <code>a-zA-Z0-9</code>, but the value generated from this is 7 characters long. This length is still long enough and I want to convert to about 4-5 characters.</p>
  <p>Is there a general way to do this or some method in which this can be done so that recovering the integer would still be possible? I am asking the mathematical aspects here but I would be programming this in PHP and I recently started programming in php.</p>
  <h1>Edit:</h1>
  <p>I was thinking in terms of assigning a masking bit and using this in a fashion to generate less number of Chars. I am aware of the fact that the range is not enough and that is the reason I was focusing on using a mathematical trick or a way of representation. The 62 base was an Idea that I already applied but is not working out.</p>