Ejemplo n.º 1
0
<?php

require_once realpath(dirname(__FILE__) . 'snapchat.php');
require_once realpath(dirname(__FILE__) . 'reddit/corgi.php');
$corgi = file_get_contents(Corgi::fetch_corgi()) or die;
SnapchatUtil::send_photo($corgi, SnapchatUtil::get_friends_list());
exit(0);
Ejemplo n.º 2
0
<?php

$username = $_REQUEST['username'];
if (!preg_match('/^[A-Za-z0-9\\.\\-\\_]+$/', $username)) {
    die('failure');
}
require '../snapchat.php';
SnapchatUtil::add_friend($username);
die('success');