Thursday, December 31, 2009

fontreplace - PHP/jQuery Font Replacement (FLIR)

Lately I was quite into web design and interface so much that I started exploring sIFR and FLIR. Yesterday I decided to develop a FLIR for PHP and jQuery.

You can download the fontreplace package at: (122 kB, zip format).

  • PHP 4.4.2 and above compatible
  • Uses jQuery Javascript Framework
  • Transparent background for CSS background support
  • Lightweight
  • Reads font color, font size, and font dynamically.
  • Detects whether user has font before loading from server
  • 100% SEO Friendly and minimal code changes
  • Supports font color RGBA with alpha.
  • Tested working on IE7, IE8, FF 2.0, 3.0, 3.5, Safari (Win) 4.0 and Chrome 3.0, 4.0

The demo and example is inside the zip file. Place the content of the zip file on a PHP-enabled server and run it on the browser.

Sunday, December 27, 2009

The Art of Password Protection in PHP

While I was working on some algorithm on PHP earlier on, I began to thought about the methods of password protection when I was still a novice in PHP, till now where I stand. Here's a little bit on how I went through the stages of password protection.

The Art of Password Protection, MD5, SHA1, Salting, php code

Of course my website wasn't hack and I wasn't that bad NOT to hash the password at all. When I started off building my first website, betaPod, I actually used MD5 for password to be hashed. Afterwhich, I learnt about how MD5 passwords can be rainbow-tabled and cracked, and came to know about what is called salting.

Then when I thought that if salting is not enough, I came up with positions of the salt based on the password entered, which makes the hash very unique and secured.

You can definitely use the code in the image.