Skip to content

Instantly share code, notes, and snippets.

View insign's full-sized avatar
🇧🇷
being open-sourcerer

Hélio insign

🇧🇷
being open-sourcerer
View GitHub Profile
@insign
insign / curl.sh
Last active November 2, 2021 18:30 — forked from exAspArk/curl.sh
Test CORS with cURL (case insensitive)
curl -I -X OPTIONS \
-H "Origin: http://EXAMPLE.COM" \
-H 'Access-Control-Request-Method: GET' \
http://EXAMPLE.COM/SOMETHING 2>&1 | grep -i 'Access-Control-Allow-Origin'
@insign
insign / 2018_02_13_142413_add_renews_at_column_to_subscriptions.php
Last active January 31, 2024 07:55 — forked from garygreen/2018_02_13_142413_add_renews_at_column_to_subscriptions.php
Sync Stripe Renewal Date for all subscriptions - Laravel Console Command
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddRenewsAtColumnToSubscriptions extends Migration
{
/**
* Run the migrations.
@insign
insign / watchlist.php
Created November 7, 2015 05:08
Sync IMDb watchlist to trakt.tv watchlist. Usage: php -f watchlist.php trakt_apikey trakt_username trakt_passwordhash imdb_login imdb_password imdb_uid (IMDb login is email adress or nickname, it's NOT the ur12345678 bit, that's the imdb_uid)
<?php
define('TRAKT_APIKEY', $argv[1]);
define('TRAKT_USERNAME', $argv[2]);
define('TRAKT_PASSWORD', $argv[3]);
define('IMDB_EMAIL', $argv[4]);
define('IMDB_PASSWORD', $argv[5]);
define('IMDB_UID', $argv[6]);
function curl_post($urlpre, $data, $urlpost = '')