Welcome To Our Shell

Mister Spy & Souheyl Bypass Shell

Current Path : /var/www/html/ift/web/core/modules/file/src/Plugin/Field/FieldFormatter/

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/ift/web/core/modules/file/src/Plugin/Field/FieldFormatter/DefaultFileFormatter.php

<?php

namespace Drupal\file\Plugin\Field\FieldFormatter;

use Drupal\Core\Field\FieldItemInterface;
use Drupal\Core\Form\FormStateInterface;

/**
 * Formatter for a text field on a file entity that links the field to the file.
 *
 * @FieldFormatter(
 *   id = "file_link",
 *   label = @Translation("File link"),
 *   field_types = {
 *     "string"
 *   }
 * )
 */
class DefaultFileFormatter extends BaseFieldFileFormatterBase {

  /**
   * {@inheritdoc}
   */
  public static function defaultSettings() {
    $settings = parent::defaultSettings();
    $settings['link_to_file'] = TRUE;

    return $settings;
  }

  /**
   * {@inheritdoc}
   */
  public function settingsForm(array $form, FormStateInterface $form_state) {
    // We don't call the parent in order to bypass the link to file form.
    return $form;
  }

  /**
   * {@inheritdoc}
   */
  protected function viewValue(FieldItemInterface $item) {
    return $item->value;
  }

}

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