Skip to content

Instantly share code, notes, and snippets.

View finagin's full-sized avatar
🖖

Igor Finagin finagin

🖖
View GitHub Profile
<?php
function send_push_ios( $message, $data = array() ) {
// Это паскод от сертификата
$passphrase = "Gergemona123";
// Ссылка на файл сертификата на сервере
$sert_file = __DIR__ . '/gto_client.pem';
// Ссылка на сервер Apple
// песочница

Keybase proof

I hereby claim:

  • I am finagin on github.
  • I am finagin (https://keybase.io/finagin) on keybase.
  • I have a public key ASAX0qhk8IAQYtU9Ee5Kc6-ZQRYDQajVGO24kdKrEVPUego

To claim this, I am signing this object:

// ...
/**
* Media sizes
*/
$media_aliases = {
palm: '(max-width: 480px)'
lap: '(min-width: 481px) and (max-width: 1023px)'
lap-and-up: '(min-width: 481px)'
portable: '(max-width: 1023px)'
desk: '(min-width: 1024px)'
@finagin
finagin / filesystems.php
Last active March 14, 2017 11:28
config/filesystems.php
<!-- config/filesystems.php -->
<?php
// ...
'default' => 'local',
// ...
@finagin
finagin / filesystems.php
Last active March 14, 2017 11:29
config/filesystems.php
<!-- config/filesystems.php -->
<?php
// ...
'default' => 'public',
// ...
@finagin
finagin / web.php
Created March 14, 2017 12:31
routes/web.php
<!-- routes/web.php -->
<?php
// ...
Route::posr('/store', function (Request $request) {
// validate
// ...
// fileUpload is input name
if ($request->hasFile('fileUpload')) {
@finagin
finagin / AbstractComparable.php
Last active July 3, 2017 13:55
Comparable & Equalsable abstract class
<?php
namespace Finagin\Ad\Helpers;
use Exception;
abstract class AbstractComparable
{
/**
* Equals $this and $other instances
<?php
function panorama($file_name, $water_mark = false, $r = 255, $g = 255, $b = 255)
{
list($width_x, $size) = getimagesize($file_name);
if ($width_x < $size) {
throw new Exception('The panorama must be horizontal');
}
<!-- leyouts/app.blade.php -->
@if (View::hasSection('breadcrumb'))
@yield('breadcrumb')
@else
@yield('title', 'Dashboard')
@endif
<!-- files/create.blade.php -->
@extends('layouts.app')