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 snoop(/*args*/) { | |
| console.log.apply(console, Array.prototype.slice.call(arguments)) | |
| return arguments[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
| if (typeof crypto === 'undefined' || crypto == null) crypto = require('crypto') | |
| var _MAX_CRYPTO_BYTES = 65536 | |
| var _BYTES_IN_UINT32 = 4 | |
| var _MAX_CRYPTO_UINT32 = Math.floor(_MAX_CRYPTO_BYTES / _BYTES_IN_UINT32) | |
| if (!crypto.getRandomValues) | |
| crypto.getRandomValues = function (buffer) { | |
| var randomBytes = crypto.randomBytes(buffer.buffer.byteLength) |
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
| var Point = Isomer.Point | |
| var Path = Isomer.Path | |
| var Shape = Isomer.Shape | |
| var Vector = Isomer.Vector | |
| var Color = Isomer.Color | |
| var rotationDuration = 2 * 1000 | |
| var canvas = document.getElementById("canvas") | |
| Math.TwoPI = Math.PI * 2 |
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
| var reverse = function(str) { | |
| str = str.split('') | |
| var end = str.length - 1 | |
| for (var i = 0; i + 1 <= end - i; ++i) { | |
| var t = str[i] | |
| str[i] = str[end - i] | |
| str[end - i] = t | |
| } | |
| return str.join('') |
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
| // 0) | |
| private void UpdateErrorResponseLog(CommandResponseElement[] array, long id) | |
| { | |
| //Logging all errors and response messages returned to TOA_InboundAPI_Response_Errors table | |
| try{ | |
| foreach (CommandResponseElement value in array) |
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
| // http://stackoverflow.com/questions/61817/whats-the-best-method-in-asp-net-to-obtain-the-current-domain | |
| Request.Url.Scheme + System.Uri.SchemeDelimiter + Request.Url.Host + (Request.Url.IsDefaultPort ? "" : ":" + Request.Url.Port) |
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
| <script type="text/javascript"> | |
| (function($) { | |
| $(document).ready(function() { | |
| $("#ctl00_MasterBody_MyPhoneNumbers1_RadGrid1_ctl00_ctl04_imgbtnVoicemail") | |
| .attr("id", "anti_telerik_hack" + Math.random()) | |
| .attr("name", "anti_telerik_hack" + Math.random()) | |
| .off() | |
| .click(function() { alert("Pardon the Interruption. The service you are looking for is unavailable at the moment. We will be back up on January 20, so please call 1-855-287-5969 for assistance with your Voicemail changes. Thank you for your patience."); return false; }); | |
| }); | |
| })($telerik.$); |
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
| import qualified Data.Char as Char | |
| import Data.List | |
| capitalized :: String -> String | |
| capitalized "" = "" | |
| capitalized (head:tail) = Char.toUpper head : tail | |
| trimmer :: ([a] -> a) -> ([a] -> [a]) -> (a -> Bool) -> [a] -> [a] | |
| trimmer _ _ _ [] = [] | |
| trimmer next rest pred l |
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
| begin | |
| -- These first three would be the function arguments. | |
| declare @property_name nvarchar(32) = 'CurrentAcct' | |
| declare @prop_encoding nvarchar(64) = 'CurrentTN:S:0:10:CurrentSite:S:10:3:CurrentAcct:S:13:8:' --'CurrentSite:S:0:3:CurrentAcct:S:3:8:' | |
| declare @properties nvarchar(32) = '501463909143229127406' --'43731870303' | |
| declare @propval_index bigint = PATINDEX('%' + @property_name + ':%', @prop_encoding) + LEN(@property_name) + 1 | |
| declare @propval_start_index bigint = CHARINDEX(':', @prop_encoding, @propval_index) + 1 | |
| declare @propval_start_index_len bigint = CHARINDEX(':', @prop_encoding, @propval_start_index) - @propval_start_index | |
| declare @propval_len_index bigint = @propval_start_index + @propval_start_index_len + 1 |
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
| NodeSql = Npm.require 'mssql' | |
| Connection = NodeSql.Connection | |
| Request = NodeSql.Request | |
| Transaction = NodeSql.Transaction | |
| wrapProtoFunc = (klass, name) -> | |
| Meteor.wrapAsync klass.prototype[name] | |
| class wRequest extends Request |