Init Git Prod Mars 2026
This commit is contained in:
commit
d81efe93b1
362 files changed
+86627
No files matched your search
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
require_once __DIR__ .'/../../includes/bootstrap_global.php';
|
||||
require_once '../vendor/autoload.php';
|
||||
$config = require 'config_google.php';
|
||||
|
||||
$client = new Google_Client();
|
||||
$client->setClientId($config['client_id']);
|
||||
$client->setClientSecret($config['client_secret']);
|
||||
$client->setRedirectUri($config['redirect_uri']);
|
||||
$client->addScope(Google_Service_Calendar::CALENDAR_EVENTS);
|
||||
$client->setAccessType('offline'); // important pour refresh_token
|
||||
$client->setPrompt('consent');
|
||||
|
||||
$auth_url = $client->createAuthUrl();
|
||||
header('Location: ' . filter_var($auth_url, FILTER_SANITIZE_URL));
|
||||
exit;
|
||||
Reference in new issue
Block a user