The code you posted from the ssl.inc file was malicious. It contained hyperlinks to about 50 websites selling those drugs. They were served when the visitor to the page was Googlebot, bingbot, or msnbot. That would help explain why only the robots saw the links, and you didn't when you visited your pages yourself.
(I removed most of the code because there is no point leaving it publicly available.)
Deleting the file was the correct thing to do, but you should find out if Drupal was supposed to have a legitimate file with that name in that folder. If so, you'll need to find the legitimate version of the file, and put it back there. Maybe the Drupal forum can help you. ( http://drupal.org/forum
Deleting the file was a good first step, but the hackers were able to put the file there because there is a security hole somewhere. You'll need to improve your security or they will put the file there again.
You should do the security precautions described on my page http://25yearsofprogramming.com/blog/20070705.htm
and the other related pages.