Creating an SSH Config file for server shortcuts

If you SSH into a lot of different servers, you may want to create an SSH Config file so that you can use shortcuts to do the commands.  This post will go over the basic steps of creating an SSH Config File. Without this file if you wanted to SSH to a server, you needed […]

WordPress and jQuery – Get by Element ID not working

I racked my brain on this one for a bit the other day.  So I figured I would make a post on it to hopefully help some others. During my development of a WordPress plugin I was having trouble with WordPress and jQuery working together.  In particular, having jQuery interact with a Form element inside of […]

PHP Script to validate a phone number

This is a fast and simple script to validate a phone number. The purpose of this script is to keep things simple.  The scripts cleans input whether it is passed as a numeric value or as a string.  It then validates it’s count of numbers found present in the value, then returns only the numbers […]

PHP Script to validate an Email Address

I do a lot of programming that requires validation of user data – including a users email address. When I am collecting this data via a Web Form, I like to use the JQuery Validate plugin to give immediate feedback to my user when they have not entered an e-mail address properly. In addition, I like […]

PHP Array to Object and Object to Array

In your php applications you may find many circumstances where it is needed to convert an object into an array and an array into an object. One common example of this usage is in Server <-> Client communications.  The server may want to store items in an array for sorting and iteration.  By contrast, the […]

PHP Script to generate a random salt

There are many times and circumstances in your programming that you may need to write and generate a random salt.  This may be include: Creating passwords for users Coupon codes Random identification strings When this is needed, many programming languages have a default random function of some kind.  For example, in PHP you have RAND […]

Using a hashing algorithm to validate a password

Security on your website is a critical detail to pay close attention to.  This post will help you use a hashing algorithm to store and validate user authentication details, such as passwords. If you have a site that stores user authentication data, you will want to use a hashing algorithm to store and validate the […]

PHP Array of Common Stop Words

There are many different circumstances in which a PHP Array of Common Stop Words could come in handy. One of the most useful is if you have some sort of blog, article or page creator in your website. Using meaningful titles in the URL is a strong strategy to increase your SEO results. However you […]

Script to Install PhantomJS on a Linux CentOS Machine

What is PhantomJS? PhantomJS is a headless WebKit scriptable with a JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG. Download v1.9 Get started. The project homepage for PhantomJS can be found here: http://phantomjs.org/ In this post we will show you how to download and […]