vBulletin Social Group Icons in Postbit

Here's a quick plugin I wrote for vBulletin to display social group icons on the postbit. The social group icon for each public social group the user belongs to will be displayed. Please see attachment.

To install, just import the plugin via the admin panel.

This plugin was only tested on vBulletin 3.8 on http://www.b15u.com. Please use at your own risk.

MS SQL Class

This code is still beta, use at your own risk.

<?php
 
	class redDB {
 
		private $__db_host;
		private $__db_username;
		private $__db_password;
		private $__db_name;
		private $__db_handle;
 
		private $__sql;
		private $__table_name;
		private $__result;
 
		private $__statement;
 
		function __construct($host, $username, $password, $db_name){
 
			$this->__db_host = $host;
			$this->__db_username = $username;
			$this->__db_password = $password;
			$this->__db_name = $db_name;
 
			$this->connect();
		}
 
		/**
		 * Initialize our table object

jQuery vs. MooTools

"Most people getting started with JavaScript these days are faced with the challenging task of picking a library to use, or at least which one to learn first. If you're working for a company chances are they have already chosen a framework for you, in which case the point is somewhat moot. If this is the case and they've chosen MooTools and you're used to jQuery, then this article might still be of some use to you. "

Written by Aaron Newton

Article here:
http://jqueryvsmootools.com/

QuantCast Screen Scraper

This is a quick and dirty screen scraper for quantcast.com. It currently only grabs the site rank and description.

Usage:

		$q = new QuantCast('cnet.com');
		echo '<strong>Rank:</strong> ' . $q->getRank() . '<br />';
		echo '<strong>Desc:</strong> ' . $q->getDescription() . '<br />';

Class Source Code:

	class QuantCast {
 
		public $siteName;
		private $siteContents;
 
		public function __construct($siteName){
			$this->siteName = strtolower(str_replace('http://', '', $siteName));

PHP MySQLi Table to Object Class

This class requires PHP 5.2+ and the MySQLi extension. It will not work with the regular MySQL extension. An object representing a table is created on the fly that will allow you to do inserts, updates etc.

Please see comments in the code for usage.

<?php
	/**
	 * Create's an object representing a table in a database
	 * This class requires a database handle to be passed in
	 *
	 * @version 1.0
	 *
	 * @example
	 * 	$db = new redDB('host', 'username', 'password', 'database_name');
	 * 	$user = $db->init('user_table');
	 * 	$user->get("user_id = 4343");