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 glitchfx(lines) | |
| local lines=lines or 64 | |
| for i=1,lines do | |
| row=flr(rnd(128)) | |
| row2=flr(rnd(127)) | |
| if (row2>=row) row2+=1 | |
| // copy a row from the | |
| // screen into temp memory |
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
| /* | |
| HTML to add to exported | |
| <button id="goleft" onmousedown="btnpress(1)" onmouseup="btnpress()">UP</button> | |
| <p><button id="goleft" onmousedown="btnpress(4)" onmouseup="btnpress()">LEFT</button> | |
| <button id="goleft" onmousedown="btnpress(2)" onmouseup="btnpress()">RIGHT</button></p> | |
| <button id="goleft" onmousedown="btnpress(3)" onmouseup="btnpress()">DOWN</button> | |
| <hr> | |
| <button id="goleft" onmousedown="btnpress(5)" onmouseup="btnpress()">Z</button> | |
| <button id="goleft" onmousedown="btnpress(6)" onmouseup="btnpress()">X</button> | |
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
| /* | |
| Instagram Embed Link Sniffer - Converts Instagram links into embeds | |
| Requires jQuery + Instagram API JS | |
| https://platform.instagram.com/en_US/embeds.js | |
| */ | |
| var Instabed = { | |
| mark_class: "instagram-link", |
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
| <style> | |
| .container { | |
| width: 500px; | |
| margin: 0 auto; | |
| } | |
| .progress_outer { | |
| border: 1px solid #000; | |
| } | |
| .progress { | |
| width: 0%; |
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
| .row:after { content:""; display:table; clear:both; } | |
| .row > .c { float:left; position:relative; } | |
| @mixin cols($suffix) { | |
| .row > .c25#{$suffix} { width:25%; } | |
| .row > .c30#{$suffix} { width:30%; } | |
| .row > .c33#{$suffix} { width:33%; } | |
| .row > .c50#{$suffix} { width:50%; } | |
| .row > .c66#{$suffix} { width:66%; } |
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
| /* | |
| |-------------------------------------------------------------------------- | |
| | Autoload Custom Controllers | |
| |-------------------------------------------------------------------------- | |
| | http://stackoverflow.com/questions/21351808/codeigniter-extending-controller-controller-not-found | |
| | | |
| | Add this to the bottom of /config/config.php | |
| | | |
| | As long as your library is prefixed with "MY_" and lives in the /core/ folder, this will | |
| | autoload that library when you extend without having to otherwise include it. |
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 | |
| // Derived from: http://stackoverflow.com/questions/12358228/mustache-php-idiomatic-ways-to-template-select-dropdowns | |
| require './Mustache/Autoloader.php'; | |
| Mustache_Autoloader::register(); | |
| $m = new Mustache_Engine(array( | |
| 'loader' => new Mustache_Loader_FilesystemLoader(dirname(__FILE__)."/", array('extension' => '.html')), | |
| 'partials_loader' => new Mustache_Loader_FilesystemLoader(dirname(__FILE__)."/", array('extension' => '.html')) | |
| )); |
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
| <? | |
| class MY_Model extends CI_Model { | |
| protected $_table; | |
| protected $_primarykey; | |
| function __construct() { | |
| parent::__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
| $(document).on('click', function(event) { | |
| if (!$(event.target).closest('#element-to-exclude').length) { | |
| // hide menu code | |
| } | |
| }); |
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 array_pull($array, $pull) { | |
| $result = array(); | |
| foreach ($pull as $key) { | |
| if (array_key_exists($key, $array)) { | |
| $result[$key] = $array[$key]; | |
| } | |
| } | |
| return($result); | |
| } |