So here's the scenario. I was looking to have the a panel with exact dimensions on a C# form (700x400). I wanted even and default spacing around the panel on the form. I figured out the default spacing was 12, so I set the size of the form to 724x424 …
read moreOther articles
Useful One-Line PHP files
Here are a couple useful PHP commands that you can run on your server to get useful information.
This one gives basic information about the PHP installation, which can be used for troubleshooting or just verifying that PHP is running.
<?php phpinfo(); ?>
This one tells you the name of the …
read morePuTTY SSH Tunnel for MySQL
I just stumbled across the MySQL GUI Tools Bundle which is very useful for managing a MySQL databases. In my opinion, it's much easier than using phpMyAdmin, which I had been doing previously. The only problem is that using it "requires" the machine the database is on (my web server …
read moreDjango Admin Media Files on Apache
I had quite a bit of fun trying to get Apache to serve the admin files for my Django install. Here are the settings I used to finally get it to work. Note that the site is in a subdirectory of my domain. I'm not currently hosting any other media …
read morePHP Equal-Sign Operators
Reading some php code, you might get confused about the difference betweeen =, ==, and === (this single, double, and triple equal signs). Here's a quick summary.
= (Assignment) Just like in (pretty much) every other programming language.
== (Equality) Returns true if the two variables have the same value.
=== (Identity) Returns true if the …
read moreMySQL Change current auto-increment value
You can use the following SQL query to set the next value to be used by an auto-incrementing field in MySQL. Useful if you make a mistake and want to delete a value you just added without leaving a gap in the sequence numbers, or if you want to start …
read more