# booktics/1.0.28/core/onboard/init-onboard.php

Booktics – Appointment Booking Calendar for Service Businesses, version 1.0.28. 40 lines.

- Page: https://pluginprobe.com/plugins/booktics/1.0.28/code/core/onboard/init-onboard.php
- Raw: https://pluginprobe.com/plugins/booktics/1.0.28/raw/core/onboard/init-onboard.php
- Modified: 2026-10-05T09:02:00+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/booktics/1.0.28/code/core/onboard/init-onboard.php#L10-L20`.

```php
<?php

namespace Booktics\Onboard;

if ( ! defined( 'ABSPATH' ) ) exit;

use Booktics\Contracts\Hookable_Service_Contract;

/**
 * Handles initialization of onboarding process for first-time plugin installation
 *
 * @package Booktics/Onboard
 */
class Init_Onboard implements Hookable_Service_Contract {

    /**
     * Register admin init action
     *
     * @return void
     */
    public function register() {
        add_action( 'admin_init', array( $this, 'init' ) );
    }

    /**
     * Initializes onboarding process by checking if plugin is installed
     * If not installed, sets installation flag and redirects to onboarding page
     *
     * @return void
     */
    public function init() {
        $is_installed = get_option( 'booktics_is_installed', false );
        if ( ! $is_installed ) {
            update_option( 'booktics_is_installed', true );
            wp_safe_redirect( admin_url( 'admin.php?page=booktics#/onboard' ) );
            exit();
        }
    }
}

```
