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
/* | |
jQuery UI Sortable plugin wrapper for $firebaseArray | |
@param [ui-sortable] {object} Options to pass to $.fn.sortable() merged onto ui.config | |
*/ | |
angular.module('ui.sortable', []) | |
.value('uiSortableConfig',{}) | |
.directive('uiSortable', [ | |
'uiSortableConfig', '$timeout', '$log', | |
function(uiSortableConfig, $timeout, $log) { |
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
/* | |
Watch out, os.IsExist(err) != !os.IsNotExist(err) | |
They are error checkers, so use them only when err != nil, and you want to handle | |
specific errors in a different way! | |
Their main purpose is to wrap around OS error messages for you, so you don't have to test | |
for Windows/Unix/Mobile/other OS error messages for "file exists/directory exists" and | |
"file does not exist/directory does not exist" |
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
// Go to "All Applications" / "Settings" / "Pricing templates" and select the template you want to export | |
javascript: (function(e, s) { | |
e.src = s; | |
e.onload = function() { | |
jQuery.noConflict(); | |
console.log('jQuery injected'); | |
$ = jQuery; | |
extractData(); | |
}; |
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
# chmod +x wifiremember.sh, then | |
# type `crontab -e` and add this line : | |
* * * * * $HOME/wifiremember/wifiremember.sh |
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
FROM openfl/openfl:develop | |
## install node/npm | |
ADD https://deb.nodesource.com/setup_8.x /opt/node8setup.sh | |
RUN chmod +x /opt/node8setup.sh && /opt/node8setup.sh | |
RUN apt-get install -y --no-install-recommends nodejs | |
## tests need these modules, let's have them in global namespace | |
RUN npm install http-server -g | |
RUN npm install webpack -g |
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
// check browser console in https://try.haxe.org/#cFBDb | |
class Trace { | |
static function main() { | |
var a = {}; | |
Reflect.setProperty(a, "b", "c"); | |
trace("before"); | |
trace("a"); |
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
package lime._backend.html5; | |
import js.html.KeyboardEvent; | |
import js.Browser; | |
import lime.app.Application; | |
import lime.app.Config; | |
import lime.media.AudioManager; | |
import lime.graphics.Renderer; | |
import lime.ui.GamepadAxis; |
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
var _data:Dynamic = ...; | |
var cache:Array<Dynamic> = []; | |
var jsonString = haxe.Json.stringify(_data, function(key:Dynamic, value:Dynamic) { | |
// kill keys you don't want here | |
// if(key == "ba") return null; | |
// only filter objects | |
if(value != null && Reflect.isObject(value)) { | |
if(cache.indexOf(value) > -1) { |
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 | |
/* | |
only important name is the filter name : | |
pods_admin_ui_PODNAME | |
if your pods is called "client" then call it | |
pods_admin_ui_client | |
you can rename all functions to your liking | |
*/ | |
add_filter( 'pods_admin_ui_PODNAME', 'custom_admin_table_columns_for_PODNAME' ); |
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
$('.post').off('click') | |
function postClick() { | |
console.log($(this)); | |
var results = $(this).nextUntil('.post'); | |
var a = 0; | |
for(i=0;i<results.length;i++) { | |
if($(results[0]).hasClass('threading')) { | |
a++; | |
$(results[0]).toggle(); |
OlderNewer