-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathReference.php
More file actions
30 lines (27 loc) · 1 KB
/
Reference.php
File metadata and controls
30 lines (27 loc) · 1 KB
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
<?php
/*
Plugin Name: Insert Link Reference In Copied Text
Description: This plugin will add a reference from which site someone copied a text.
Author: Mushlih Almubarak
Author URI: https://github.com/mushlih-almubarak
Version: 2
*/
// Include functions.php, use require_once to stop the script if the functions.php file is not found
require_once plugin_dir_path(__FILE__) . 'Functions.php';
// Connect action hook 'admin_menu', run 'ILRICT_add_setting_menu' function
add_action('admin_menu', 'ILRICT_add_setting_menu');
// Add menu link in WordPress dashboard
function ILRICT_add_setting_menu()
{
add_menu_page(
'Insert Link Reference In Copied Text', // Page title
'Insert Reference', // The text displayed on the menu
'manage_options', // Requirements to be able to view the link
'insert-link-reference-in-copied-text', // Permalink.
'ILRICT_setting' // Call the "ILRICT_setting" function
);
function ILRICT_setting()
{
require_once 'Setting.php';
}
}