PHP Class Tutorial – Part 2 – What is $this->

Please make sure you’ve followed my first PHP Class Tutorial before starting this one, as it follows on using the previous example. This tutorial will explain what $this-> is all about, and how to further your PHP class knowledge!

Read More…

Posted in OOP, PHP at August 18th, 2010. 17 Comments.

Simple PHP MySQL Class

That’s right! I have a simple MySQL class file that you can use in your PHP projects. I’ve been using it for years, and it’s never let me down!

You can grab it on my Github: http://github.com/a1phanumeric/PHP-MySQL-Class.

Read More…

Posted in Featured, MySQL, PHP at August 17th, 2010. 7 Comments.

How to make URL Safe strings for mod_rewrite using PHP

It’s relatively easy to make URL safe strings for use by mod_rewrite. Let’s use the example that you have a form that adds a new blog post to your site. When the user submits this form, you want to generate a URL safe string (based on the title of the blog post) for mod_rewrite to use. This little snippet will show you how this can be achieved in one line of code in PHP.
Read More…

Posted in Mod_Rewrite, PHP, Tools at July 11th, 2010. 3 Comments.

Top iPhone Games

Top iPhone Games is a new site I’ve just released which shows you the top iPhone / iPad / iPod games based on data aggregated from across the internet – so it’s unbiased!

Visit Top iPhone Games now and let me know your feedback!

Posted in iPhone, iPad, Ipod at June 2nd, 2010. No Comments.

Control your iPhone iPod playback with your headphones.

I have to say, I haven’t tested this on anything other than an iPhone 3G S, but hey I couldn’t find anything out there for this, so here you go!

This is a list of key presses on (what seems like a very simple implementation of) the headphone control for the iPod. This list will show you how you can play, pause, skip forward, skip backward and even fast-forward / rewind your songs on your iPhone / iPod with just the headphone controls.

  • To play a song, press the middle of the control once.
  • To stop a song, press the middle of the control once (when a song is playing)
  • To increase the volume, press the top of the button (with the plus sign)
  • To decrease the volume, press the bottom of the button (with the minus sign)
  • To skip forward a track, double click the middle button.
  • To skip back a track, triple click the middle button
  • To fast forward a track, double click and hold down the middle button
  • To rewind a track, triple click and hold down the middle button

That is all!

Posted in iPhone Tips at May 14th, 2010. No Comments.

Solution to Form Submit 403 Error

Have you ever had a problem where you get a HTTP 403 error from submitting a form?
Does this form have a field that submits a URL?

If yes to the above two questions, I think I know the problem you’re having, and have a solution. It’s to do with mod_security (an Apache module) and the ‘http://’ part of the URL.

Read More…

Posted in JavaScript at February 10th, 2009. 3 Comments.

PHP Date Picker

This is a simple to use script that can be called at anytime to insert a date picker into your form.

Example


Read More…

Posted in PHP at January 16th, 2009. 6 Comments.

Functions Inc.

Functions Inc. is a new site I’ve started for all you guys to add your code snippets to. It’s an online code snippet repository where you can add your useful snippets, as well as view others. You can keep your snippets private, just using the site as an online code library, or choose to share them with others.

Why not head over there now and check it out. It’s free!

Posted in Tools at January 4th, 2009. No Comments.

Awesome Form Validation

I don’t know about you, but I always work hard on my form validation (and would never use just JUST JavaScript to validate input locally). It puts a smile on my face when a form is technically valid, yet won’t submit:

Awesome Form Validation

Posted in Uncategorized at June 25th, 2008. 7 Comments.

Simple Web 2.0 Design and CSS Tutorial

This tutorial aims at teaching you how to make a simple “Web 2.0″ design.

Download Tutorial Files

View Final Design Read More…

Posted in CSS, Photoshop at March 17th, 2008. 12 Comments.