-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathtournament_scheduler.php
32 lines (26 loc) · 1009 Bytes
/
tournament_scheduler.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<?php
/*
Plugin Name: Tournament Scheduler
Plugin URI:
Description: a simple tournament scheduler that lets users of your site signup for beach volleyball tournaments.
Handles a series of tournament with that automatically calculates the seeding based on the result of past tournaments
Author: Sindre Øye Svendby
Version: 0.6-SNAPSHOT
Author URI:
*/
include __DIR__ . "/vendor/autoload.php";
//Not triggered on update since 3.1
register_activation_hook(__FILE__, 'tournament_scheduler_activate');
register_deactivation_hook(__FILE__, 'tournament_scheduler_deactivate');
add_action( 'plugins_loaded', 'tournament_scheduler_activate' );
function tournament_scheduler_activate() {
require_once dirname(__FILE__).'/tournament_scheduler_loader.php';
$loader = new TournamentSchedulerLoader();
$loader->activate();
}
function tournament_scheduler_deactivate() {
require_once dirname(__FILE__).'/tournament_scheduler_loader.php';
$loader = new TournamentSchedulerLoader();
$loader->deactivate();
}
?>