HEX
Server: Apache
System: Linux www3.pit.tblive.com 5.14.0-687.38.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Aug 12 17:19:12 EDT 2026 x86_64
User: awaldron (1020)
PHP: 8.1.34
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //home/awaldron/_domains/phlibrary.alanwaldron.com/wp-content/themes/phlibrary/admin/admin.php
<?php

add_action( 'admin_menu', 'phlib_admin' );
function phlib_admin() {
    add_menu_page( 'Penn Hills Library', 'PH Library', 'edit_others_posts', 'PHLibrary', 'phlib_admin_page', get_stylesheet_directory_uri() . '/img/admin-icon.png');
}

add_action( 'admin_menu', 'phlib_events_admin' );
function phlib_events_admin() {
    add_submenu_page('PHLibrary', 'Events', 'Events Manager', 'edit_others_posts', 'phlib_events', 'phlib_events');
}

add_action( 'admin_menu', 'phlib_hours_menu' );
function phlib_hours_menu() {
    add_submenu_page('PHLibrary', 'Library Hours', 'Library Hours', 'edit_others_posts', 'phlib_hours', 'phlib_hours');
}

add_action( 'admin_menu', 'phlib_new_noteworthy' );
function phlib_new_noteworthy() {
    add_submenu_page('PHLibrary', 'New & Noteworthy', 'New & Noteworthy', 'edit_others_posts', 'phlib_noteworthy', 'phlib_noteworthy');
}

require_once("phlib_noteworthy.php");
require_once("phlib_events.php");
require_once("phlib_hours.php");

function phlib_admin_page() {
    echo '    
    <div class="wrap">
        <h1 class="wp-heading">Penn Hills Library Administration</h1>
        <hr>
        <br><br>
        <ul style="font-size:30px;line-height:50px;margin-left:50px;">
        <li style="list-style-type: disc;"><a href="/wp-admin/admin.php?page=phlib_events">Events Manager</a></li>
        <li style="list-style-type: disc;"><a href="/wp-admin/admin.php?page=phlib_hours">Library Hours</a></li>
        <li style="list-style-type: disc;"><a href="/wp-admin/admin.php?page=phlib_noteworthy">New & Noteworthy</a></li>
        </ul>
    </div>
        ';
}