This is a quick snippet of code I created to dynamically pull a user-defined query from a MySQL database.
Read More »Posted on January 28, 2010 in PHP Tutorials and has been tagged as excel, mysql, php.
Here’s a quick snippet of code that allows you to quickly generate a random string of letters and/or numbers based on the variables you feed into the function.
Read More »Posted on January 8, 2010 in PHP Tutorials and has been tagged as php.
This problem came up while working with the Allegheny County Property database. They have a field for the sale date of the property, only they’re storing the date like this – 3291982 for 03/29/1982.
Read More »Posted on September 30, 2009 in PHP Tutorials and has been tagged as dates, php.
Take an array of numbers, strip out the dollar sign and format them correctly.
This is useful when you are given prices as varchar or text with the dollar sign already included in the field. We’re going to start with an array of numbers, in this case we’ll use the array(‘$1256.45′,’$5564.75′,’$7895.33′).
Here is the foreach loop running: [...]
Posted on August 7, 2009 in PHP Tutorials and has been tagged as php.
My name is Andy Weigel and I'm a web developer and designer in Pittsburgh, PA.
I focus on combining design with technology to build compelling, creative, easy-to-navigate web sites and custom web applications for organizations and businesses of all shapes and sizes. My specialty is WordPress. And most of all, I love what I do!