Skip to content

Instantly share code, notes, and snippets.

View Kradre's full-sized avatar
💭
Trying to get all ideas together

Kradre Kradre

💭
Trying to get all ideas together
View GitHub Profile
@jgaydos
jgaydos / ubuntu18.04_php7.4_sqlsrv.sh
Created February 5, 2020 20:26
Ubuntu 18.04 + PHP7.4 + SQLSRV
#!/bin/bash
#ubuntu 18.04
#php7.4
# install php ppa
apt -y install software-properties-common
add-apt-repository ppa:ondrej/php -y
apt update
@phosphoer
phosphoer / TexturePackDefinition.cs
Last active July 22, 2024 19:52
TexturePackDefinition.cs
// The MIT License (MIT)
// Copyright (c) 2024 David Evans @festivevector
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF O
@all3kcis
all3kcis / Emby-theater-premiere-bypass.md
Last active September 17, 2024 11:06
Emby Theater premiere bypass
@Pitasi
Pitasi / check_telegram_signature.js
Last active May 19, 2024 08:51
Telegram website login widget, signature check sample using Node.js
// Copied by https://gist.github.com/dotcypress/8fd12d6e886cd74bba8f1aa8dbd346aa,
// thanks for improving code style
const { createHash, createHmac } = require('crypto');
const TOKEN = "ABC:12345...";
// I prefer get the secret's hash once but check the gist linked
// on line 1 if you prefer passing the bot token as a param
const secret = createHash('sha256')
.update(TOKEN)
@yurivictor
yurivictor / get_video_info.php
Last active July 7, 2017 07:28
Get video information from url and convert to array
<?php
/**
* Get video information and convert to array
* @param string $url, the url of the video
* @uses wp_remote_get()
* @return array $video, information about the video
*/
function get_video( $url ) {
$video = array();