in reply to Script runs from command line but not via crontab

...alll of the above, plus: when you run a cron job it does not usually invoke a login shell. The effect of that is then dependant on which shell you are using, and what is in your startup files. If critical environment variables are set in a startup file then you may find they are not set - PATH is an example and is mentioned above.

I have to say that your 'if' statements are laborious, try using preset hash.
Update:
%languagenames = ("English" => "en", "Indonesian" => "id", "Chinese" => "zh", "Danish" => "da", "German" => "de", "Spanish" => "es", "Esperanto" => "eo", "French" => "fr", "Italian" => "it" "Creole" => "cpf", "Dutch" => "nl", "Norwegian" => "no", "Polish" => "pl", "Portuguese" => "pt" "Russian" => "ru", "Finnish" => "fi", "Swedish" => "sv", "Turkish" => "tr");
The hash should be global, or a state variable if you have 5.10. Then in the subroutine:
%language = $languagenames{$languagename};
You can use a simple array for the month numbers.