Skip to content

Instantly share code, notes, and snippets.

View bekco's full-sized avatar

Behçet MUTLU bekco

View GitHub Profile
@bekco
bekco / gist:91ff4669b4409f723a623cbb098b1483
Last active February 22, 2018 10:00
\Twig_Function_Method to \Twig_Function definition regex replacer
# find:
'([a-z_A-Z]+)' *=> *new \\([A-Za-z_]+)_Method\(.*, *'([a-zA-Z_]+)'\)
# replace:
new \\$2('$1', [\$this, '$3'])
@bekco
bekco / ResourceOwnerGrantExtension.php
Last active May 8, 2019 06:36
How to Authenticate (Facebook, Google +, Twitter etc.) users with HWIOauthBundle and FOSOauthServerBundle from iOS, Android or third party application using API.
<?php
/**
* User: bekco (Behçet Mutlu)
* Date: 17/11/16
* Time: 17:52
*/
namespace Acme\Oauth2Bundle\Oauth\Extension;