Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀
// TODO: be life good

William Correa wilcorrea

🚀
// TODO: be life good
View GitHub Profile
View rc4.js
/*
* RC4 symmetric cipher encryption/decryption
*
* @license Public Domain
* @param string key - secret key for encryption/decryption
* @param string str - string to be encrypted/decrypted
* @return string
*/
function rc4(key, str) {
var s = [], j = 0, x, res = '';
View gist:c825c91d37f80b462dbe
<?php
define('HOST', 'www.site.com.br');
$hostname = 'imap.' . HOST;
$username = 'catch@' . HOST;
$password = '**************';
$options = array("port" => 143, "settings" => array("notls"), "tagged" => "INBOX");
$imap = new Imap($hostname, $username, $password, $options);
View likeit.php
<?php
$supino = array(
'm' => array(
'a'=>array(
'Superior'=>(object)['min'=>1.34, 'max'=>5]
, 'Excelente'=>(object)['min'=>1.2, 'max'=>1.33]
, 'Boa'=>(object)['min'=>1.07, 'max'=>1.19]
, 'Média'=>(object)['min'=>0.9, 'max'=>1.6]
, 'Fraca'=>(object)['min'=>0, 'max'=>0.89]
@wilcorrea
wilcorrea / index.html
Created Aug 9, 2016 — forked from k33g/index.html
Vue.js + ES6
View index.html
<div id="demo">
<h1>{{bob.fields.firstName}} {{bob.fields.lastName}}</h1>
</div>
<ul id="humans-list">
<li v-repeat="humans">
{{fields.firstName}} {{fields.lastName}}
</li>
</ul>
View rodada.php
<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.1.2/css/bulma.min.css"
integrity="sha256-8TT9mHOU3psGaXjyZO82K8wm1ZwLUwWhN5zeZOxJ1Qs=" crossorigin="anonymous" />
</head>
<body>
<div class="container">
<h1 class="title is-2">Placar da Rodada</h1>
@wilcorrea
wilcorrea / README.md
Created Sep 26, 2016 — forked from addyosmani/README.md
108 byte CSS Layout Debugger
View README.md

CSS Layout Debugger

A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.

One-line version to paste in your DevTools

Use $$ if your browser aliases it:

~ 108 byte version

View ComponentWithModal.vue
<script>
import UseModal from './shared/modal/UseModalMixin.js';
export default {
mixins: [UseModal],
};
</script>
<template>
<modal size="md" v-ref:modal>
@wilcorrea
wilcorrea / fancy-tabs-demo.html
Created Oct 5, 2016 — forked from ebidel/fancy-tabs-demo.html
Fancy tabs web component - shadow dom v1, custom elements v1, full a11y
View fancy-tabs-demo.html
<script>
function execPolyfill() {
(function(){
// CustomElementsV1.min.js v1 polyfill from https://github.com/webcomponents/webcomponentsjs/tree/v1/src/CustomElements/v1.
/*
Copyright (c) 2016 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
@wilcorrea
wilcorrea / index.php
Last active Oct 5, 2016
receive use cors
View index.php
<?php
header("Access-Control-Allow-Origin: *");
$output = [
'input' => null,
'post' => null,
'get' => null,
];
You can’t perform that action at this time.