Welcome To Our Shell

Mister Spy & Souheyl Bypass Shell

Current Path : /var/www/html/rocksensor1/web/modules/contrib/visitors/src/Form/

Linux ift1.ift-informatik.de 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
Upload File :
Current File : /var/www/html/rocksensor1/web/modules/contrib/visitors/src/Form/Referer.php

<?php

namespace Drupal\visitors\Form;

use Drupal\Core\Form\FormStateInterface;
use Drupal\visitors\VisitorsReportInterface;

/**
 * Referer type filter form.
 */
class Referer extends DateFilter {

  /**
   * {@inheritdoc}
   */
  public function getFormId() {
    return 'visitors_referer_form';
  }

  /**
   * {@inheritdoc}
   */
  public function buildForm(array $form, FormStateInterface $form_state) {
    $this->setSessionRefererType();
    $form = parent::buildForm($form, $form_state);

    unset($form['submit']);

    $form['visitors_referer'] = [
      '#type'          => 'fieldset',
      '#title'         => $this->t('Referer type filter'),
      '#collapsible'   => FALSE,
      '#collapsed'     => FALSE,
      '#description'   => $this->t('Choose referer type'),
    ];

    $form['visitors_referer']['referer_type'] = [
      '#type' => 'select',
      '#title' => 'Referer type',
      '#default_value' => $_SESSION['referer_type'],
      '#options' => [
        $this->t('Internal pages'),
        $this->t('External pages'),
        $this->t('All pages'),
      ],
    ];

    $form['submit'] = [
      '#type'          => 'submit',
      '#value'         => $this->t('Save'),
    ];

    return $form;
  }

  /**
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    parent::submitForm($form, $form_state);

    $_SESSION['referer_type'] = $form_state->getValues()['referer_type'];
  }

  /**
   * Set to session info default values for visitors referer type.
   */
  protected function setSessionRefererType() {
    if (!isset($_SESSION['referer_type'])) {
      $_SESSION['referer_type'] = VisitorsReportInterface::REFERER_TYPE_EXTERNAL_PAGES;
    }
  }

}

bypass 1.0, Devloped By El Moujahidin (the source has been moved and devloped)
Email: contact@elmoujehidin.net bypass 1.0, Devloped By El Moujahidin (the source has been moved and devloped) Email: contact@elmoujehidin.net