Inheritance: extends Frontend
 /**
  * Return if there are no files
  * @return string
  */
 public function generate()
 {
     // Use the home directory of the current user as file source
     if ($this->useHomeDir && FE_USER_LOGGED_IN) {
         $this->import('FrontendUser', 'User');
         if ($this->User->assignDir && $this->User->homeDir) {
             $this->folderSRC = $this->User->homeDir;
         }
     }
     // Return if there is no folder defined
     if (empty($this->folderSRC)) {
         return '';
     }
     // Get the folders from the database
     $this->objFolder = \FilesModel::findByUuid($this->folderSRC);
     if ($this->objFolder === null) {
         if (!\Validator::isUuid($this->folderSRC[0])) {
             return '<p class="error">' . $GLOBALS['TL_LANG']['ERR']['version2format'] . '</p>';
         }
         return '';
     }
     $file = \Input::get('file', true);
     // Send the file to the browser and do not send a 404 header (see #4632)
     if ($file != '' && !preg_match('/^meta(_[a-z]{2})?\\.txt$/', basename($file))) {
         if (strpos(dirname($file), $this->objFolder->path) !== FALSE) {
             \Controller::sendFileToBrowser($file);
         }
     }
     return parent::generate();
 }
 /**
  * Return if there are no files
  * @return string
  */
 public function generate()
 {
     $this->arrItems = deserialize($this->visJsTimeline_items);
     // Return if there is no data defined
     if (empty($this->visJsTimeline_items)) {
         return '';
     }
     return parent::generate();
 }
 /**
  * Extend the parent method
  *
  * @return string
  */
 public function generate()
 {
     if ($this->vimeo_albumId == '') {
         return '';
     }
     if (TL_MODE === 'BE') {
         return '<p><a href="https://vimeo.com/album/' . $this->vimeo_albumId . '" target="_blank">https://vimeo.com/album/' . $this->vimeo_albumId . '</a></p>';
     }
     return parent::generate();
 }
 /**
  * Display a wildcard in the back end
  *
  * @return string
  */
 public function generate()
 {
     if (TL_MODE == 'BE') {
         /** @var BackendTemplate|object $objTemplate */
         $objTemplate = new \BackendTemplate('be_wildcard');
         $objTemplate->wildcard = '### ' . Utf8::strtoupper($GLOBALS['TL_LANG']['FMD']['comments'][0]) . ' ###';
         $objTemplate->title = $this->headline;
         return $objTemplate->parse();
     }
     return parent::generate();
 }
 /**
  * Display a wildcard in the back end
  * @return string
  */
 public function generate()
 {
     if (TL_MODE == 'BE') {
         $this->strTemplate = 'be_wildcard';
         $this->Template = new \BackendTemplate($this->strTemplate);
         $this->Template->wildcard = '### SLICK SLIDER START ###';
         $this->Template->title = $this->headline;
         return $this->Template->parse();
     }
     return parent::generate();
 }
 /**
  * Show the raw markdown code in the back end
  *
  * @return string
  */
 public function generate()
 {
     if (TL_MODE == 'BE') {
         $return = '<pre>' . \StringUtil::specialchars($this->code) . '</pre>';
         if ($this->headline != '') {
             $return = '<' . $this->hl . '>' . $this->headline . '</' . $this->hl . '>' . $return;
         }
         return $return;
     }
     return parent::generate();
 }
 public function editContentElement($objRow, $strBuffer)
 {
     /**
      * @var $objRow \ContentModel
      */
     if (TL_MODE == 'BE') {
         $objRow->space = null;
     }
     $prefix = 'box';
     $strClass = ContentElement::findClass($objRow->type);
     if (!$this->classFileExists($strClass)) {
         $this->log('Content element class "' . $strClass . '" (content element "' . $objRow->type . '") does not exist', 'Controller getContentElement()', TL_ERROR);
         return '';
     }
     $objElement = new $strClass($objRow);
     $arrCssClass = explode(' ', $objElement->cssID[1]);
     $arrCssClass[] = $prefix . $objElement->boxSystem;
     $objElement->cssID = array($objElement->cssID[0], implode(' ', array_filter($arrCssClass)));
     $strBuffer = $objElement->generate();
     return $strBuffer;
 }
 /**
  * Extend the parent method
  *
  * @return string
  */
 public function generate()
 {
     if ($this->vimeo_videoId == '') {
         return '';
     }
     // Generate the backend buffer
     if (TL_MODE === 'BE') {
         $buffer = '<p><a href="https://vimeo.com/' . $this->vimeo_videoId . '" target="_blank">https://vimeo.com/' . $this->vimeo_videoId . '</a>';
         // Display the hint that the video is linked to URL
         if ($this->vimeo_link) {
             $buffer .= ' - ' . sprintf($GLOBALS['TL_LANG']['MSC']['vimeo.video_link'], $this->url);
         }
         $buffer .= '</p>';
         // Display the video image
         if (($video = $this->getVideo()) !== null) {
             $buffer .= '<figure><img src="' . $video->getPoster() . '" width="160" height="" alt=""></figure>';
         }
         return $buffer;
     }
     return parent::generate();
 }
 /**
  * Return if there are no files
  *
  * @return string
  */
 public function generate()
 {
     // Use the home directory of the current user as file source
     if ($this->useHomeDir && FE_USER_LOGGED_IN) {
         $this->import('FrontendUser', 'User');
         if ($this->User->assignDir && $this->User->homeDir) {
             $this->multiSRC = array($this->User->homeDir);
         }
     } else {
         $this->multiSRC = \StringUtil::deserialize($this->multiSRC);
     }
     // Return if there are no files
     if (!is_array($this->multiSRC) || empty($this->multiSRC)) {
         return '';
     }
     // Get the file entries from the database
     $this->objFiles = \FilesModel::findMultipleByUuids($this->multiSRC);
     if ($this->objFiles === null) {
         return '';
     }
     return parent::generate();
 }
 /**
  * Initialize the content element
  * @param object
  */
 public function __construct($objElement)
 {
     parent::__construct($objElement);
 }
 /**
  * Find a content element in the TL_CTE array and return the class name
  *
  * @param string $strName The content element name
  *
  * @return string The class name
  *
  * @deprecated Deprecated since Contao 4.0, to be removed in Contao 5.0.
  *             Use ContentElement::findClass() instead.
  */
 public static function findContentElement($strName)
 {
     trigger_error('Using Controller::findContentElement() has been deprecated and will no longer work in Contao 5.0. Use ContentElement::findClass() instead.', E_USER_DEPRECATED);
     return \ContentElement::findClass($strName);
 }
 /**
  * Import the back end user object
  */
 public function __construct($param)
 {
     parent::__construct($param);
     $this->import('Database');
 }