- Redesigned the main page with a modern look and feel. - Added search and filtering functionality for drills. - Implemented pagination for browsing drills. - Added the ability for users to mark drills as favorites.
21 lines
546 B
PHP
21 lines
546 B
PHP
<?php
|
|
session_start();
|
|
|
|
require_once __DIR__ . '/vendor/autoload.php';
|
|
|
|
$config = require_once __DIR__ . '/hybridauth_config.php';
|
|
|
|
if (isset($_GET['provider'])) {
|
|
$provider = $_GET['provider'];
|
|
|
|
try {
|
|
$hybridauth = new Hybridauth\Hybridauth($config);
|
|
$adapter = $hybridauth->authenticate($provider);
|
|
header('Location: hybridauth_callback.php?provider=' . $provider);
|
|
} catch (Exception $e) {
|
|
echo 'Oops, we ran into an issue: ' . $e->getMessage();
|
|
}
|
|
} else {
|
|
echo 'Provider not specified.';
|
|
}
|