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 | |
| $loops = 1000000; | |
| $a = array(); | |
| $b = array(); | |
| for ($i = 0; $i < $loops; $i++) { | |
| $a[] = $i; | |
| $b["item{$i}"] = $i; | |
| } |
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
| // ==UserScript== | |
| // @name Anchor tags in Central | |
| // @namespace http://central.tri.be/ | |
| // @version 0.1 | |
| // @description Adds anchor tags to some links in central | |
| // @author You | |
| // @include /^https:\/\/central.tri.be(\/.*)?/ | |
| // @grant none | |
| // ==/UserScript== |
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 absint( $maybeint ) { | |
| return abs( intval( $maybeint ) ); | |
| } | |
| function sanitize_absint( $number = null ){ | |
| // If it's not numeric we forget about it | |
| if ( ! is_numeric( $number ) ){ | |
| return false; | |
| } |
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
| #!/bin/bash | |
| ######################### | |
| # This bash script pulls the latest plugin code for whichever branch is checked out | |
| # | |
| # Optionally checks out a branch before pulling. | |
| # | |
| # Example: mtup develop | |
| ######################### |
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
| // Calculate hours for any type of ticket in the next release | |
| (function( $ ) { | |
| var total = 0; | |
| $('.estimated_hours').each(function() { | |
| var $el = $( this ); | |
| var $row = $el.closest( 'tr' ); | |
| var $version = $row.find( '.fixed_version a' ); | |
| if ( 'Next Release' !== $.trim( $version.html() ) ) return; |
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 convert_recurring_event_meta() { | |
| global $wpdb; | |
| // Get meta values | |
| $event_recurrence_meta = $wpdb->get_results(" | |
| SELECT post_id, meta_value | |
| FROM $wpdb->postmeta | |
| WHERE meta_key = '_EventRecurrence' |
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
| | |
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 style="clear:both"></div> |
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
| {| width="250" align="right" class="info-box area" | |
| |- | |
| {{#if: {{{image|}}}| | |
| {{!}} colspan="2" class="info-image" {{!}} {{{image}}}}} | |
| |- | |
| | colspan="2" class="info-name" | '''{{{name}}}''' | |
| |- | |
| | colspan="2" class="info" | '''General Information''' | |
| |- |