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 ($){ | |
return { | |
property: 'myProperty', | |
method: function(){ | |
return someShit; | |
}, | |
property: 'myProperty2', | |
method: function(){ | |
return someShit2; | |
} |
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
using System; | |
using Android.App; | |
using Android.Content; | |
using Android.Runtime; | |
using Android.Views; | |
using Android.Widget; | |
using Android.OS; | |
using LoginScreen; |
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
public class ConnectionFactory { | |
public static DbConnection GetOpenConnection() { | |
var connection = new SqlConnection("MyConnectionString"); | |
connection.Open(); | |
return connection; | |
} | |
} |
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
DECLARE ARRAY S; | |
function INIT(words) | |
S ← CREATE-ARRAY(LENGTH(words)) | |
for k ← from 0 to LENGTH(words) do | |
S[k] ← EMPTY-ORDERED-SET | |
function EARLEY-PARSE(words, grammar) | |
INIT(words) | |
ADD-TO-SET((γ → •S, 0), S[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
// index.js | |
const path = require('path') | |
const express = require('express') | |
const exphbs = require('express-handlebars') | |
const port = 8080 | |
const app = express() | |
app.engine('.hbs', exphbs({ | |
defaultLayout: 'main', |
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 objToday = new Date(), | |
weekday = new Array('Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'), | |
dayOfWeek = weekday[objToday.getDay()], | |
domEnder = function() { var a = objToday; if (/1/.test(parseInt((a + "").charAt(0)))) return "th"; a = parseInt((a + "").charAt(1)); return 1 == a ? "st" : 2 == a ? "nd" : 3 == a ? "rd" : "th" }(), | |
dayOfMonth = today + ( objToday.getDate() < 10) ? '0' + objToday.getDate() + domEnder : objToday.getDate() + domEnder, | |
months = new Array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'), | |
curMonth = months[objToday.getMonth()], | |
curYear = objToday.getFullYear(), | |
curHour = objToday.getHours() > 12 ? objToday.getHours() - 12 : (objToday.getHours() < 10 ? "0" + objToday.getHours() : objToday.getHours()), | |
curMinute = objToday.getMinutes() < 10 ? "0" + objToday.getMinutes() : objToday.getMinutes(), |
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
use <DatabaseName> | |
go | |
SELECT | |
t.type AS [Type], | |
t.type_desc AS TypeDesc, | |
t.name AS Table_Name, | |
SCHEMA_NAME(schema_id) AS [Schema_Name], | |
c.name AS Column_Name |
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
CREATE FUNCTION [dbo].[RemoveSpecialCharacters](@Temp VarChar(2000)) | |
RETURNS VARCHAR(2000) | |
AS | |
BEGIN | |
DECLARE @KeepValues AS VARCHAR(50) | |
SET @KeepValues = '%[^A-Za-z0-9]%' | |
WHILE PatIndex(@KeepValues, @Temp) > 0 | |
SET @Temp = Stuff(@Temp, PatIndex(@KeepValues, @Temp), 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
Create Function [dbo].[RemoveNonNumericCharacters](@Temp VarChar(1000)) | |
Returns BigInt | |
AS | |
Begin | |
Declare @Return BigInt | |
Declare @KeepValues as varchar(50) | |
Set @KeepValues = '%[^0-9]%' | |
While PatIndex(@KeepValues, @Temp) > 0 | |
Set @Temp = Stuff(@Temp, PatIndex(@KeepValues, @Temp), 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
CREATE FUNCTION [dbo].[RemoveNonAlphaCharacters](@Temp VarChar(2000)) | |
RETURNS VARCHAR(2000) | |
AS | |
BEGIN | |
DECLARE @KeepValues AS VARCHAR(50) | |
SET @KeepValues = '%[^a-z]%' | |
WHILE PatIndex(@KeepValues, @Temp) > 0 | |
SET @Temp = Stuff(@Temp, PatIndex(@KeepValues, @Temp), 1, '') |