HEX
Server: Apache
System: Linux scp1.abinfocom.com 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User: confeduphaar (1010)
PHP: 8.1.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/confeduphaar/backip-old-files/libraries/smartslider3/src/Framework/View/AbstractBlock.php
<?php


namespace Nextend\Framework\View;


use Nextend\Framework\Pattern\GetPathTrait;
use Nextend\Framework\Pattern\MVCHelperTrait;

abstract class AbstractBlock {

    use GetPathTrait;
    use MVCHelperTrait;

    /**
     * AbstractBlock constructor.
     *
     * @param MVCHelperTrait $MVCHelper
     */
    final public function __construct($MVCHelper) {

        $this->setMVCHelper($MVCHelper);

        $this->init();
    }

    protected function init() {

    }

    protected function renderTemplatePart($templateName) {

        include self::getPath() . '/' . $templateName . '.php';
    }

    /**
     * Returns the HTML code of the display method
     *
     * @return string
     */
    public function toHTML() {

        ob_start();

        $this->display();

        return ob_get_clean();
    }

    public abstract function display();
}