$57 GRAYBYTE WORDPRESS FILE MANAGER $67

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.217.254 | ADMIN IP 216.73.216.180
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : mail

/home/bravrvjk/itiministry.org/wp-content/plugins/give/src/Helpers/

HOME
Current File : /home/bravrvjk/itiministry.org/wp-content/plugins/give/src/Helpers//Language.php
<?php

namespace Give\Helpers;

/**
 * @since 3.0.0
 */
class Language
{
    /**
     * @since 4.13.0 Added early return if the textdomain is loaded
     * @since 3.0.0
     */
    public static function load()
    {
        if (is_textdomain_loaded('give')) {
            return;
        }

        $giveRelativePath = self::getRelativePath();

        $locale = is_admin() && !wp_doing_ajax() && function_exists('get_user_locale') ? get_user_locale() : get_locale();
        $locale = apply_filters('plugin_locale', $locale, 'give'); // Traditional WordPress plugin locale filter.

        // Setup paths to current locale file.
        $moFile = sprintf('%1$s-%2$s.mo', 'give', $locale);
        $moFileLocal = trailingslashit(WP_PLUGIN_DIR) . $giveRelativePath . $moFile;
        $moFileGlobal = trailingslashit(WP_LANG_DIR) . 'plugins/' . $moFile;

        unload_textdomain('give');
        if (file_exists($moFileGlobal)) {
            load_textdomain('give', $moFileGlobal); // Look in global /wp-content/languages/plugins folder.
        } elseif (file_exists($moFileLocal)) {
            load_textdomain('give', $moFileLocal); // Look in local /wp-content/plugins/give/languages/ folder.
        } else {
            load_plugin_textdomain('give', false, $giveRelativePath); // Load the default language files.
        }
    }

    /**
     * @since 3.0.0
     */
    public static function setScriptTranslations($handle)
    {
        wp_set_script_translations($handle, 'give', trailingslashit(WP_PLUGIN_DIR) . self::getRelativePath());
    }

    /**
     * Return the plugin language dir relative path, e.g. "give/languages/"
     *
     * @since 3.0.0
     */
    public static function getRelativePath(): string
    {
        $giveRelativePath = dirname(plugin_basename(GIVE_PLUGIN_FILE)) . '/languages/';
        $giveRelativePath = ltrim(apply_filters('give_languages_directory', $giveRelativePath), '/\\');

        return trailingslashit($giveRelativePath);
    }

    /**
     * @since 3.22.0
     */
    public static function getLocale()
    {
        return apply_filters('givewp_locale', get_locale());
    }

    /**
     * @since 3.22.0
     */
    public static function switchToLocale(string $locale)
    {
        if (empty($locale) || $locale == get_locale()) {
            return;
        }

        switch_to_locale($locale);
    }
}


Current_dir [ WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
4 Apr 2026 1.57 AM
bravrvjk / bravrvjk
0755
Form
--
4 Apr 2026 1.57 AM
bravrvjk / bravrvjk
0755
Frontend
--
4 Apr 2026 1.57 AM
bravrvjk / bravrvjk
0755
Gateways
--
4 Apr 2026 1.57 AM
bravrvjk / bravrvjk
0755
ArrayDataSet.php
2.851 KB
16 Apr 2025 5.25 PM
bravrvjk / bravrvjk
0644
Call.php
0.709 KB
18 Nov 2022 3.53 AM
bravrvjk / bravrvjk
0644
Date.php
1.327 KB
12 May 2022 3.49 AM
bravrvjk / bravrvjk
0644
EnqueueScript.php
0.728 KB
1 Apr 2022 2.56 AM
bravrvjk / bravrvjk
0644
Hooks.php
3.288 KB
1 Apr 2022 2.56 AM
bravrvjk / bravrvjk
0644
Html.php
1.401 KB
24 Nov 2021 4.55 AM
bravrvjk / bravrvjk
0644
IntlTelInput.php
6.879 KB
24 Apr 2024 7.56 PM
bravrvjk / bravrvjk
0644
Language.php
2.312 KB
5 Nov 2025 7.00 PM
bravrvjk / bravrvjk
0644
Table.php
1.329 KB
24 Nov 2021 4.55 AM
bravrvjk / bravrvjk
0644
Utils.php
7.453 KB
1 May 2025 3.56 PM
bravrvjk / bravrvjk
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF