Battlefield 3 will hit the shelves October 25th, 2011 for the PC, Xbox 360, and Playstation 3. If you are a PC gamer you know you are going to want a powerful machine to experience this much anticipated release. Battlefield 3 introduces the Frostbite 2.0 engine which is based on the 1.5 engine seen in Bad Company 2, so the …
Articles in: Tutorials
Home » Archive » TutorialsJavascript & PHP Star Rating Script
June 26, 2011 # 8:15 PM # Scripts, Tutorials # No CommentI’ve searched around the interwebs for an ajax star rater and I came across a few different possibilities, all of which looked very good. The top result from google was Nick Stakenburg’s “Starbox” for “ajax star rater”. I also found Masuga Web Design’s Ajax Star Rater and a script from MySandbox to be popular results. However I couldn’t really seem …
Check if Field Exists in Mysql Table
May 10, 2011 # 1:03 PM # PHP Functions, Tutorials # No CommentSometimes it is useful to know if a field exists in a mysql table before running a query using that field name, especially when the field name is coming from some kind of user input.
So to do this we use the function mysql_list_fields to grab the fields out of a table and run through them with a for loop until …
WHMCS Cron Jobs in cPanel
February 3, 2011 # 3:46 AM # Tutorials # No CommentHere we will look at how to set up your WHMCS to run scheduled cron jobs through your cPanel. This allows you to let your clients automatically have their websites and hosting, etc. set up without actually manually doing it. It is an automation feature, which coming from your system’s cPanel, is availabile in WHMCS. Basically in cPanel you create …
Avoid Duplicate Content Pages
January 30, 2011 # 5:41 PM # HTML tags, Tutorials # No CommentMany people do not think about the possibility of duplicate content pages on their website, when this is very common and easily avoidable. All it takes is a little HTML in the head tags of the page.
What is a duplicate content page?
Duplicate content is content that is showing up on the Internet by multiple URLs. Another words, a …
HTML Div Float Property
November 10, 2010 # 2:16 PM # Code, HTML tags, Tutorials # No CommentUsing the HTML tag – <div> and the float style property, you can make designs for your websites. Well, you can make layouts for where design could be. This is a good structural tool in laying out where content will be on your web pages, images, blurbs, etc.
Let’s say we want a page to look like this:
First I’m going to …
PHP Pagination with Mysql
September 2, 2010 # 10:52 AM # Code, Tutorials # 13 CommentsSo you have a Mysql table you want to pull data from, but you don’t want to flood the page with everything in the table right! So you need some pagination to seperate all the content in the table into easy to open pages.
So let’s say this is your mysql query:
$sql = mysql_query(“SELECT * FROM table1″) or die(mysql_error());
So this will …
PHP Upload and Resize Image
July 27, 2010 # 11:21 AM # Code, Scripts, Tutorials # 23 CommentsMany times when you upload a image somewhere you want to resize it to different dimensions based off of a maximum width or height. Here is a simple script that does this for you, using a HTML form and a PHP script. We start with the PHP script that will run if our $_GET['do'] is set to “upload.” Then we …
PHP Favicon Generator Script
July 24, 2010 # 12:12 PM # Scripts, Tutorials # 8 CommentsI decided to make a free easy to use favicon generating script that uses PHP. The script has a few features and requirements when uploading your image to be converted to a favicon. First the script checks for a few things such as file type, file size, if the directory is writable, and the specified dimensions. You can create a …
PHP Ordinalize Numbers – Add Suffix
July 22, 2010 # 4:23 PM # Code, PHP Functions, Tutorials # One CommentHere is a very simple function to use to ordinalize numbers in PHP. This adds the place value suffix to numbers. So you can turn numbers like 1, 2, 3 into 1st, 2nd, 3rd.
Here is the code:
function ordinalize($int){
if(in_array(($int % 100),range(11,13))){
return $int . “th”;
} else {
switch(($int % 10)){
case 1:
return $int . “st”;
break;
case 2:
return $int . “nd”;
break;
case 3:
return $int . “rd”;
break;
default:
return $int …

Subscribe RSS
Comment RSS