This file contains hidden or 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 overload($obj){ | |
$obj->setHeader = function() $obj as $this { | |
//magic happens here | |
} | |
} | |
class Mobile_Cart_View extends Cart_View { | |
public function __construct(){ |
This file contains hidden or 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
//what we currently have | |
//test1.js | |
widget.register('test1',{ | |
//widget code | |
}); | |
//test2.js | |
widget.register('test2',{ |
This file contains hidden or 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
function Stack(){ | |
function next(){ | |
var fn = this.$stack[this.$index++]; | |
return fn && fn.apply(this, arguments); | |
} | |
function current(){ | |
var fn = this.$index === 0 ? this.$stack[this.$index] : this.$stack[this.$index -1]; | |
return fn && fn.apply(this, arguments); | |
} |
This file contains hidden or 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
/*! | |
Copyright (c) <2012> <Arieh Glazer> | |
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | |
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE |
This file contains hidden or 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
/*! | |
Copyright (c) <2012> <Arieh Glazer> | |
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | |
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE |
This file contains hidden or 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
div.tip{ | |
margin:100px 150px; | |
width:25px; | |
height:25px; | |
border:1px solid orange; | |
border-radius:50%; | |
background:linear-gradient(top, #f9f44a 2%, #ffa51e 61%, #d17308 100%); | |
position:relative; | |
cursor:pointer; | |
} |
This file contains hidden or 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
div.tip{ | |
margin:100px 150px; | |
width:25px; | |
height:25px; | |
border:1px solid orange; | |
border-radius:50%; | |
background:linear-gradient(top, #f9f44a 2%, #ffa51e 61%, #d17308 100%); | |
position:relative; | |
cursor:pointer; | |
} |
This file contains hidden or 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
div.tip{ | |
margin:100px 150px; | |
width:25px; | |
height:25px; | |
border:1px solid orange; | |
border-radius:50%; | |
background:linear-gradient(top, #f9f44a 2%, #ffa51e 61%, #d17308 100%); | |
position:relative; | |
cursor:pointer; | |
} |
This file contains hidden or 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 | |
/** | |
*Benchmark class, it's a good solution for testing your web applications and scripts! | |
*also it can be a permanent tool you can integrate into your systems that will indicate the performance of your app/script etc. | |
* Test Time and memory consumption! | |
* Example usage: | |
* | |
* <code> | |
* require('Benchmark.class.php'); | |
* Benchmark::startTimer(); |
This file contains hidden or 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
function BreakException(){} | |
function Break(){throw new BreakException;} | |
(function(window,undef){ | |
window['$each'] = function(obj,func,bind){ | |
try{ | |
switch (typeOf(obj)){ | |
case 'object': |