Blog

Sanitize Text for SQL

Published on Saturday 26, November 2011
Cross Site Scripting (XSS) and SQL Injections are some of the biggest security threats to a PHP application.  Every developer has different ways of preventing SQL Injections or malicious JavaScript from being inserted into the database. Here are some easy solutions to help safeguard your PHP applications.

mysql_real_escape_string()

mysql_real_escape_string() should always be used on data being placed into your SQL database.

Setting Cookies with PHP

Published on Saturday 26, November 2011
If you plan on building a PHP application, you'll probably end up using cookies, especially if there are user accounts. Cookies will allow you to store specific data for a certain amount of time.

EasyPHP - WAMP environment

Published on Saturday 26, November 2011
The easiest way to learn PHP is to be able to create and edit code and see instant results. When I was younger and learning I couldn't afford to have my own web server so I installed a WAMP environment - I also didn't have a spare machine laying around to toss Linux on. Unfortunately I never heard of EasyPHP until a bit ago, it was originally released in 1999, but you can Wikipedia that. What EasyPHP does it streamline the process of setting up Apache, MySQL, and PHP and installs phpMyAdmin along with other modules if you choose.

PHP Mail Class

Published on Thursday 24, November 2011
Mailer is a PHP class to help provide easier use of the PHP mail() function and error support. In all other of my scripts using the mail() function I would have lines upon lines of code just to make sure every thing sent right and provide my own error checking.

PHP Server Variables

Published on Thursday 24, November 2011
I know when I first started out learning PHP it was difficult finding good examples or live demos of simple PHP in use. Often I'd have a large number of files used to demonstrate built in PHP functions. So, to help any budding PHP developers out there I compiled a list of the PHP Server variables along with what data they provide.  $_SERVER variables can be used in multiple ways from getting information about your visitors to script security.

jQuery Contact Form

Published on Saturday 12, November 2011
I've finally started to dive into jQuery. I figured what better way to start than to make a contact form.

DateFormat PHP Class

Published on Monday 27, June 2011
DateFormat is a PHP class for easily displaying timestamps in a PHP project, along with displaying a "time since" feature, much like the one used on Facebook and other sites. A  demo of the class is available in my script playground:  glamanate.com/playground/DateFormat/.

DateFormat Class Documentation

Initialize Class

SR Photography

Published on Saturday 14, May 2011
SR Photography offered a nice gesture, if I created a PHP back-end contact form they would take infant pictures of our new born son.  Created a short and simple PHP script with field validation (NOTE: Did not design site or form, just the back-end functionality of the form).

Game Ladder Script

Published on Saturday 14, May 2011
Two years ago I decided to check out an old gaming group that I used to play with years before that. I created a plugin to seamlessly add a ladder system into their web site.  A ladder system is typically used to match one-on-one matches. This allowed the group to add friendly competition without major overhaul of their web site.  I only made one version, but I plan on developing it a little bit further. The script allows for multiple games,which are dynamically set, and requires only one additional SQL table.
Subscribe to Blog