-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjustuno.php
62 lines (56 loc) · 1.6 KB
/
justuno.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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<?php
/**
* @package Justuno Reimagined
*/
/*
Plugin Name: Justuno Reimagined
Plugin URI: https://www.justuno.com
Description: Grow your social audience, email subscribers & sales!
Version: 4.0.7
Author: Justuno
Author URI: http://www.justuno.com
License: GPLv2 or later
*/
include_once dirname(__FILE__) . '/includes/AdminPage.php';
if (!function_exists('justuno_activation')) {
register_activation_hook(__FILE__, 'justuno_activation');
function justuno_activation()
{
// send any api calls when activation
//update_option('ju4_justuno_api_key', '');
//update_option('ju4_justuno_woocommerce_token', '');
//update_option('justuno_sub_domain', 'justone.ai');
}
}
if (!function_exists('justuno_deactivation')) {
register_deactivation_hook(__FILE__, 'justuno_deactivation');
function justuno_deactivation()
{
delete_option('justuno_options');
}
}
if (is_admin()) {
require_once dirname(__FILE__) . '/includes/AdminPage.php';
} else {
require_once dirname(__FILE__) . '/includes/Frontend.php';
}
add_filter('plugin_action_links_justuno/justuno.php', 'ju4_justuno_nc_settings_link');
function ju4_justuno_nc_settings_link($links)
{
// Build and escape the URL.
$url = esc_url(
add_query_arg(
'page',
'ju4_justuno-settings-conf',
get_admin_url() . 'options-general.php'
)
);
// Create the link.
$settings_link = "<a href='$url'>" . __('Settings') . '</a>';
// Adds the link to the end of the array.
array_push(
$links,
$settings_link
);
return $links;
}