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
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); | |
class Const_class { | |
protected static $data = array(); | |
public function __construct() | |
{ | |
self::$data = array( | |
// Any initial data |
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
<?php | |
//... | |
function try_auth() | |
{ | |
// load the library | |
$this->load->library('EasyOpenID'); | |
// start the request |
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
else | |
{ | |
// This should never happen, but you can put | |
// something here if you really want to... | |
die('Woah... How did that happen...?'); | |
} |
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
/* | |
|------------------------------------------------ | |
| CallStack | |
|------------------------------------------------ | |
| | |
| A convenient way of stacking up functions | |
| | |
| @author James Brumond | |
| @copyright Copyright 2011 James Brumond | |
| @license Dual licensed under MIT and GPL |
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
// For those cases when there just isn't any other explanation... | |
if (typeof window.YourBrowserFailsError === 'undefined') { | |
window.YourBrowserFailsError = function(msg) { | |
// Make sure it is called with "new" | |
if (! this instanceof YourBrowserFailsError) { | |
return new YourBrowserFailsError(msg); | |
} | |
// Get an actual error object for the stack | |
var err = (function() { | |
var err; |
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
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE | |
Version 2, December 2004 | |
Copyright (C) 2011 Sebastien P. https://twitter.com/#!/_sebastienp | |
Everyone is permitted to copy and distribute verbatim or modified | |
copies of this license document, and changing it is allowed as long | |
as the name is changed. | |
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE |
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
// | |
// A modified, extended version of XRegExp meant to be easily implemented | |
// in PCRE style regular expression functions. | |
// | |
var pcreXRegExp = (function() { | |
var _XRegExp; | |
var pcreXRegExp = function(pattern) { | |
var del = pattern.charAt(0); | |
var lastIndex = pattern.lastIndexOf(del); | |
var fpattern = pattern.substring(1, lastIndex); |
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
Pak { | |
id: String, | |
name: String, | |
description: String, | |
pages: [ Page ] | |
} | |
Page { | |
id: String, | |
title: String, |
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
Attempt { | |
finished: Boolean, | |
score: Number, | |
answers: [{ | |
question: Question, | |
answer: [Answer], | |
score: Number | |
}] | |
} |
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
Attempt { | |
finished: Boolean, | |
score: Number, | |
answers: [{ | |
question: Question, | |
answer: [Answer], | |
score: Number | |
}] | |
} |
OlderNewer