This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>UNICODE</title> | |
</head> | |
<body style="font-size:128px;"> | |
<script> | |
var uni = ''; | |
for ( var i = 0; i < 109385; i++ ) { | |
uni += '&#' + i + '; '; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// unixtime stamps from server are PT, need to make them UTC | |
var getAdjustedDate = function ( unixtime ) { | |
if ( !unixtime ) { return new Date(); } | |
var date, dst, offset; | |
// create date object | |
if ( typeof unixtime === 'number' ) { | |
date = new Date( unixtime * 1000 ); | |
} else if ( typeof unixtime === 'string' ) { | |
unixtime = parseInt( unixtime, 10 ); | |
date = new Date( unixtime * 1000 ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Titanium.UI.setBackgroundColor('red'); | |
// root | |
var rootWin = Ti.UI.createWindow({ | |
title: 'Root Win', | |
backgroundColor: 'gray', | |
tabBarHidden: true, | |
navBarHidden: true | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// exploring javascript's nefarious this | |
this.level = 0; | |
var test = { | |
level: 1, | |
method: function () { | |
console.log( this.level ); | |
}, | |
test: { | |
level: 2, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ti.UI.setBackgroundColor( '#000' ); | |
var clearBtn = Ti.UI.createButton({ | |
title: 'Clear' | |
}); | |
var addBtn = Ti.UI.createButton({ | |
title: 'Add' | |
}); | |
var win = Ti.UI.createWindow({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ti.UI.setBackgroundColor( '#000' ); | |
var openButton = Ti.UI.createButton( { | |
title: 'Open Win' | |
} ); | |
var win = Ti.UI.createWindow( { | |
title: 'Root Win', | |
tabBarHidden: true, | |
rightNavButton: openButton |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ti.UI.setBackgroundColor( '#000' ); | |
var rows; | |
var openButton = Ti.UI.createButton( { | |
title: 'Open Win' | |
} ); | |
var win = Ti.UI.createWindow( { | |
title: 'Root Win', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MySQLWrapper { | |
private $db = array( | |
'host' => null, | |
'name' => null, | |
'user' => null, | |
'pass' => null, | |
'pdo' => null | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Document { | |
private $_text; | |
public function __get( $name ) { | |
echo 'Document __get( ' . $name . ' )<br />'; | |
$method = 'get' . $name; | |
if ( !method_exists( $this, $method ) ) { return null; } | |
return $this->$method(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class PDOwrapper { | |
// | |
// VARIABLES | |
private $db = array( | |
'host' => null, | |
'name' => null, | |
'user' => null, | |
'pass' => null, | |
'pdo' => null |
OlderNewer