Tag Archives: php

Hash as filename

md5, sha1, etc are very handy tools for programmers to generate hashed strings from random or fixed keys. A lot of the times, we simply store these hashes directly into databases, setting the field data type as string, or use the hashes as filenames (handy for creating cache files) or as part of URL. While [...]

Posted in Tips | Also tagged , , , , , , | 2 Comments

Connect to IBM DB2 on PHP via ODBC

This was done and tested on a Linux (CentOS) system running PHP 4. Configure PHP with ODBC support. You should check that it is successfully installed by doing phpinfo(). Obtain the latest DB2 ODBC driver from IBM. You can download it from here. Lookout for Driver for ODBC and CLI. Untar it at a dir. [...]

Posted in Database, Tips | Also tagged , , , , , , , | 2 Comments