Skip to content

Instantly share code, notes, and snippets.

View B3none's full-sized avatar
๐Ÿฐ
Ah, it's a piece of cake, so it is!

B3none B3none

๐Ÿฐ
Ah, it's a piece of cake, so it is!
View GitHub Profile
@B3none
B3none / steam-profile.php
Created October 3, 2018 20:56
Basic script which allows us to scrape the avatar and name of a steam profile
<?php
function getProfile($steamId) {
$contents = file_get_contents('https://steamcommunity.com/profiles/' . $steamId);
$dom = new DOMDocument();
libxml_use_internal_errors(true);
$dom->loadHTML($contents);
libxml_clear_errors();
@B3none
B3none / discord-dm-destroyer.js
Last active March 31, 2022 11:46
Here's a cheeky mass DM delete for Discord.
let deleteMessages = (username, authToken, before = false) => {
const channel = window.location.href.split('/').pop();
const baseURL = `https://discordapp.com/api/channels/${channel}/messages`;
const headers = {
"Authorization": authToken
};
let clock = 0;
let interval = 400;
var emojis = [
'๐Ÿ˜„','๐Ÿ˜ƒ','๐Ÿ˜€','๐Ÿ˜Š','โ˜บ','๐Ÿ˜‰','๐Ÿ˜','๐Ÿ˜˜','๐Ÿ˜š','๐Ÿ˜—','๐Ÿ˜™','๐Ÿ˜œ','๐Ÿ˜','๐Ÿ˜›','๐Ÿ˜ณ','๐Ÿ˜','๐Ÿ˜”','๐Ÿ˜Œ','๐Ÿ˜’','๐Ÿ˜ž','๐Ÿ˜ฃ','๐Ÿ˜ข','๐Ÿ˜‚','๐Ÿ˜ญ','๐Ÿ˜ช','๐Ÿ˜ฅ','๐Ÿ˜ฐ','๐Ÿ˜…','๐Ÿ˜“','๐Ÿ˜ฉ','๐Ÿ˜ซ','๐Ÿ˜จ','๐Ÿ˜ฑ','๐Ÿ˜ ','๐Ÿ˜ก','๐Ÿ˜ค','๐Ÿ˜–','๐Ÿ˜†','๐Ÿ˜‹','๐Ÿ˜ท','๐Ÿ˜Ž','๐Ÿ˜ด','๐Ÿ˜ต','๐Ÿ˜ฒ','๐Ÿ˜Ÿ','๐Ÿ˜ฆ','๐Ÿ˜ง','๐Ÿ˜ˆ','๐Ÿ‘ฟ','๐Ÿ˜ฎ','๐Ÿ˜ฌ','๐Ÿ˜','๐Ÿ˜•','๐Ÿ˜ฏ','๐Ÿ˜ถ','๐Ÿ˜‡','๐Ÿ˜','๐Ÿ˜‘','๐Ÿ‘ฒ','๐Ÿ‘ณ','๐Ÿ‘ฎ','๐Ÿ‘ท','๐Ÿ’‚','๐Ÿ‘ถ','๐Ÿ‘ฆ','๐Ÿ‘ง','๐Ÿ‘จ','๐Ÿ‘ฉ','๐Ÿ‘ด','๐Ÿ‘ต','๐Ÿ‘ฑ','๐Ÿ‘ผ','๐Ÿ‘ธ','๐Ÿ˜บ','๐Ÿ˜ธ','๐Ÿ˜ป','๐Ÿ˜ฝ','๐Ÿ˜ผ','๐Ÿ™€','๐Ÿ˜ฟ','๐Ÿ˜น','๐Ÿ˜พ','๐Ÿ‘น','๐Ÿ‘บ','๐Ÿ™ˆ','๐Ÿ™‰','๐Ÿ™Š','๐Ÿ’€','๐Ÿ‘ฝ','๐Ÿ’ฉ','๐Ÿ”ฅ','โœจ','๐ŸŒŸ','๐Ÿ’ซ','๐Ÿ’ฅ','๐Ÿ’ข','๐Ÿ’ฆ','๐Ÿ’ง','๐Ÿ’ค','๐Ÿ’จ','๐Ÿ‘‚','๐Ÿ‘€','๐Ÿ‘ƒ','๐Ÿ‘…','๐Ÿ‘„','๐Ÿ‘','๐Ÿ‘Ž','๐Ÿ‘Œ','๐Ÿ‘Š','โœŠ','โœŒ','๐Ÿ‘‹','โœ‹','๐Ÿ‘','๐Ÿ‘†','๐Ÿ‘‡','๐Ÿ‘‰','๐Ÿ‘ˆ','๐Ÿ™Œ','๐Ÿ™','โ˜','๐Ÿ‘','๐Ÿ’ช','๐Ÿšถ','๐Ÿƒ','๐Ÿ’ƒ','๐Ÿ‘ซ','๐Ÿ‘ช','๐Ÿ‘ฌ','๐Ÿ‘ญ','๐Ÿ’','๐Ÿ’‘','๐Ÿ‘ฏ','๐Ÿ™†','๐Ÿ™…','๐Ÿ’','๐Ÿ™‹','๐Ÿ’†','๐Ÿ’‡','๐Ÿ’…','๐Ÿ‘ฐ','๐Ÿ™Ž','๐Ÿ™','๐Ÿ™‡','๐ŸŽฉ','๐Ÿ‘‘','๐Ÿ‘’','๐Ÿ‘Ÿ','๐Ÿ‘ž','๐Ÿ‘ก','๐Ÿ‘ ','๐Ÿ‘ข','๐Ÿ‘•','๐Ÿ‘”','๐Ÿ‘š','๐Ÿ‘—','๐ŸŽฝ','๐Ÿ‘–','๐Ÿ‘˜','๐Ÿ‘™','๐Ÿ’ผ','๐Ÿ‘œ','๐Ÿ‘','๐Ÿ‘›','๐Ÿ‘“','๐ŸŽ€','๐ŸŒ‚','๐Ÿ’„','๐Ÿ’›','๐Ÿ’™','๐Ÿ’œ','๐Ÿ’š','โค','๐Ÿ’”','๐Ÿ’—','๐Ÿ’“','๐Ÿ’•','๐Ÿ’–','๐Ÿ’ž','๐Ÿ’˜','๐Ÿ’Œ','๐Ÿ’‹','๐Ÿ’','๐Ÿ’Ž','๐Ÿ‘ค','๐Ÿ‘ฅ','๐Ÿ’ฌ','๐Ÿ‘ฃ','๐Ÿ’ญ','๐Ÿถ','๐Ÿบ','๐Ÿฑ','๐Ÿญ','๐Ÿน','๐Ÿฐ','๐Ÿธ','๐Ÿฏ','๐Ÿจ','๐Ÿป','๐Ÿท','๐Ÿฝ','๐Ÿฎ','๐Ÿ—','๐Ÿต','๐Ÿ’','๐Ÿด','๐Ÿ‘','๐Ÿ˜','๐Ÿผ','๐Ÿง','๐Ÿฆ','๐Ÿค','๐Ÿฅ','๐Ÿฃ','๐Ÿ”','๐Ÿ','๐Ÿข','๐Ÿ›','๐Ÿ','๐Ÿœ','๐Ÿž','๐ŸŒ','๐Ÿ™','๐Ÿš','๐Ÿ ','๐ŸŸ','๐Ÿฌ','๐Ÿณ','๐Ÿ‹','๐Ÿ„','๐Ÿ','๐Ÿ€','๐Ÿƒ','๐Ÿ…','๐Ÿ‡','๐Ÿ‰','๐ŸŽ','๐Ÿ','๐Ÿ“','๐Ÿ•','๐Ÿ–','๐Ÿ','๐Ÿ‚','๐Ÿฒ','๐Ÿก','๐ŸŠ','๐Ÿซ','๐Ÿช','๐Ÿ†','๐Ÿˆ','๐Ÿฉ','๐Ÿพ',
@B3none
B3none / howtoinstallsequeler.md
Last active April 4, 2021 06:10
How to install Sequeler

Sequeler Installation

Linux Ubuntu 18.04

Download the .deb package

cd ~/Downloads

wget http://packages.elementary.io/appcenter/pool/main/c/com.github.alecaddd.sequeler/com.github.alecaddd.sequeler_0.5.5_amd64.deb

Install the .deb package

sudo dpkg -i com.github.alecaddd.sequeler_0.5.5_amd64.deb

@B3none
B3none / mobileCheck.js
Created January 25, 2018 15:03
A javascript check whether the user is on mobile
() => {
var deviceData = navigator.userAgent || navigator.vendor || window.opera;
return
/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i.test(deviceData) ||
/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea
.navbar
.caret
.label
.table
.img-responsive
.img-rounded
.img-thumbnail
.img-circle
.sr-only
.lead
@B3none
B3none / StatusCodeHandler.php
Created September 6, 2017 14:49
HTTP Error handling class
<?php
class StatusCodeHelper
{
const ERROR_CODES = [
100 => 'Continue',
101 => 'Switching Protocols',
102 => 'Processing',
200 => 'OK',
201 => 'Created',