Skip to content

Instantly share code, notes, and snippets.

View josephscott's full-sized avatar

Joseph Scott josephscott

View GitHub Profile
<?php
$test_me = array();
$test_me['name'] = 'Joseph Scott';
$test_me['city'] = 'Sandy';
$test_me['state'] = 'Utah';
echo "MEM: " . memory_get_peak_usage() . "\n";
<?php
$test_me = new StdClass();
$test_me->name = 'Joseph Scott';
$test_me->city = 'Sandy';
$test_me->state = 'Utah';
echo "MEM: " . memory_get_peak_usage() . "\n";
<?php
class Test {
public $name;
public $city;
public $state;
public function __construct( $name, $city, $state ) {
$this->name = $name;
$this->city = $city;
$this->state = $state;
<?php
require 'PasswordHash.php';
$hasher = new PasswordHash( 8, FALSE );
$password1 = '012345678901234567890123456789012345678901234567890123456789012345678901';
$password2 = $password1 . 'Z';
echo "PASS1 : {$password1}\n";
$hash1 = $hasher->HashPassword( $password1 );
echo "HASH1 : {$hash1}\n";