Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

Alexander J. Rodriguez D. AlexR1712

🏠
Working from home
Block or report user

Report or block AlexR1712

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@AlexR1712
AlexR1712 / Enigma.php
Created Oct 26, 2017 — forked from Cloud5Ideas/Enigma.php
PHP Enigma Machine
View Enigma.php
<?php namespace App\Services;
/**
* A PHP version of the Enigma machine.
* Wikipedia: http://en.wikipedia.org/wiki/Enigma_machine
*
* This might not be an accurate representation. I have never seen, nor used an enigma machine.
* This class was created by reading the article at http://enigma.louisedade.co.uk/howitworks.html.
*
* Usage:
@AlexR1712
AlexR1712 / image.php
Created Oct 23, 2017
gaussian blur in one sector of the image PHP
View image.php
<?php
$loadFile = 'https://c1.staticflickr.com/5/4094/4809804115_40f52c8f25_b.jpg';
$image = imagecreatefromstring(file_get_contents($loadFile));
if ($image !== false) {
$face = imagecrop($image, ['x' => 152, 'y' => 568, 'width' => 199, 'height' => 199]);
@AlexR1712
AlexR1712 / 0x00000.bin
Created Oct 12, 2017 — forked from ajfisher/0x00000.bin
ESP8266 Transparent bridge to J5
@AlexR1712
AlexR1712 / tumblr.js
Created Oct 7, 2017
Tumblr Post type Text, thumbnails
View tumblr.js
/* Created by AlexR1712 */
function getImg (str) {
var m,
urls = [],
rex = /<img[^>]+src="(http:\/\/[^">]+)"/g;
while ( m = rex.exec( str ) ) {
urls.push( m[1] );
}
return urls;
}
View developtome.js
!function(t){function e(i){if(n[i])return n[i].exports;var o=n[i]={i:i,l:!1,exports:{}};return t[i].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:i})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="./",e(e.s=0)}({"/6JT":function(t,e,n){t.exports=n.p+"assets/images/profil-03.jpg"},0:function(t,e,n){t.exports=n("JkW7")},"1/9l":function(t,e,n){(function(t){+function(t){"use strict";function e(e){return this.each(function(){var i=t(this),o=i.data("bs.tooltip"),r="object"==typeof e&&e;!o&&/destroy|hide/.test(e)||(o||i.data("bs.tooltip",o=new n(this,r)),"string"==typeof e&&o[e]())})}var n=function(t,e){this.type=null,this.options=null,this.enabled=null,this.timeout=null,this.hoverState=null,this.$element=null,this.inState=null,this.init("tooltip",t,e)};n.VERSION="3.3.7"
View developtome.css
@import url(https://fonts.googleapis.com/css?family=Hind+Siliguri:300,600|Martel:400,900);@import url(https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css);/*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;l
@AlexR1712
AlexR1712 / cv2_detect.py
Created Sep 10, 2017 — forked from npinto/cv2_detect.py
Simple face detection with OpenCV 'cv2' python bindings from 2.4.x
View cv2_detect.py
import cv2
import cv2.cv as cv
def detect(img, cascade_fn='haarcascades/haarcascade_frontalface_alt.xml',
scaleFactor=1.3, minNeighbors=4, minSize=(20, 20),
flags=cv.CV_HAAR_SCALE_IMAGE):
cascade = cv2.CascadeClassifier(cascade_fn)
rects = cascade.detectMultiScale(img, scaleFactor=scaleFactor,
View solveshit.js
var isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
if (!isFirefox) {
document.styleSheets[2].addRule("::-webkit-scrollbar-thumb", "background: "+document.getElementsByTagName('meta')['theme-color'].content+';');
}
@AlexR1712
AlexR1712 / snippets.js
Created Jul 19, 2017
Snnipets JS time scheduling
View snippets.js
// source https://supple.com.au/tools/facebook-messenger-website-chat-widget/#
var ot = Array();
ot['mon'] = '9:00 AM-5:00 PM';
ot['tue'] = '9:00 AM-5:00 PM';
ot['wed'] = '9:00 AM-5:00 PM';
ot['thu'] = '9:00 AM-5:00 PM';
ot['fri'] = '9:00 AM-5:00 PM';
ot['sat'] = '9:00 AM-5:00 PM';
ot['sun'] = '9:00 AM-5:00 PM';
var tz = '-04:00,0';
@AlexR1712
AlexR1712 / LogMeIn.php
Created May 20, 2017 — forked from kmark/LogMeIn.php
PHP implementation of cPanel's Perl LogMeIn class.
View LogMeIn.php
<?php
namespace cPanel;
/**************************************************************************************
* Copyright (c) 2013, cPanel, Inc. *
* All rights reserved. *
* *
* Redistribution and use in source and binary forms, with or without modification, *
* are permitted provided that the following conditions are met: *
* *
You can’t perform that action at this time.