summaryrefslogtreecommitdiff
path: root/common.php
blob: e246b299b94cdea0d13e820678479dfa9cd087cb (plain)
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
<?php
    /*
     * Copyright (C) 2024 dwlr <dweller@cabin.digital>
     *
     * BSD 3-Clause License (BSD-3-Clause)
     * See LICENSE for details
     */


    $root    = (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . $_SERVER['HTTP_HOST'];
    $manbin  = "/home/dwlr/nfs_red/deb_man/mandoc/bin/man";
    $manpath = "/home/dwlr/nfs_red/deb_man/mans/bookworm/man";
    require  "$manpath/archs.php";

    $action  = trim($_GET['action']  ?? null);
    $query   = trim($_GET['query']   ?? null);
    $section = trim($_GET['section'] ?? null);
    $arch    = trim($_GET['arch']    ?? null);


    /*
    function dbg_print($data)
    {
        $output = $data;
        if(is_array($output)) $output = implode(',', $output);
        echo "<script>console.log('srv => " . $output . "' );</script>";
    }
    */
?>