Weird Internet Explorer Print Bug Involving IFRAME and TABLE

I ran into a very strange bug with printing in IE. It happened in an online calendar program that I work on. Somebody showed me a printed page from IE 6 where the attendees, which are in an IFRAME, had this big 6 inch left margin. The table was pushed off the right edge of the paper, you couldn’t even read it. On screen, the page looked just fine, there was a 10 pixel border. I printed the same page in Firefox and it printed just fine.

Read moreWeird Internet Explorer Print Bug Involving IFRAME and TABLE

Throttle down your bandwidth

Just found this, think I might try it out sometime:
http://www.xk72.com/charles/index.html

See what your site looks like with low bandwidth or latency. Also, Charles can act as a man-in-the-middle for HTTP/SSL communication, enabling you to debug the content of your HTTPS sessions, but I would recommend Mozilla LiveHeaders (http://livehttpheaders.mozdev.org/) for viewing headers, post data, etc..

Read moreThrottle down your bandwidth

Using Curl 101

To use Curl in PHP, you must have the Curl extension compiled in –with-curl, and you’ll want –with-openssl, if you need to be able to hit https pages.

Once you get PHP working with Curl (I could explain how to do that, but for this article, I am focusing on how to use it).

The code below is for PHP5, but I’m sure you could modify it to work with PHP4, just have to change the syntax a bit.

Read moreUsing Curl 101

PHP Sessions using MySQL

MySQL sessions are “gotta have it” thing if your site ever grows beyond single server. If you have multiple servers behind a load balancer, you could keep session data on a shared SAN, but MySQL makes for a better session store.

Create a file called MySession.php and put this code in it, replace the definitions to match your database. Also, it requires the PEAR DB.php module, make sure you have pear DB installed: pear install DB.

Read morePHP Sessions using MySQL

Problems with multiple versions (4.0, 4.1) with mysqld_safe

I am running mysql-standard-4.0.20-pc-linux-i686 and mysql-standard-4.1.12-pc-linux-gnu-i686 on the same machine, installed binaries.
I had a heck of a time running both of these versions at once. And not for the typical reasons: port collision, sock file, etc… I have that all figured out, I should be able to run two versions of MySQL on the same machine. I am running 4.0 out of /usr/local/mysql and trying to run 4.1 out of /usr/local/mysql-4.1 and cannot get it working for the life of my, using the mysqld_safe script.

Read moreProblems with multiple versions (4.0, 4.1) with mysqld_safe