Rain \ Tpl \ NotFoundException
Template index not found! Rain\Tpl\NotFoundException thrown with message "Template index not found!" Stacktrace: #5 Rain\Tpl\NotFoundException in /home/ebargello/domains/e-bargello.com/public_html/Libs/View.php:127 #4 App\Libs\View:checkTemplate in /home/ebargello/domains/e-bargello.com/public_html/Libs/View.php:57 #3 App\Libs\View:draw in /home/ebargello/domains/e-bargello.com/public_html/Controllers/Index.php:306 #2 App\Controllers\Index:brands in /home/ebargello/domains/e-bargello.com/public_html/vendor/illuminate/routing/Controller.php:54 #1 Illuminate\Routing\Controller:callAction in /home/ebargello/domains/e-bargello.com/public_html/Libs/Boot.php:47 #0 App\Libs\Boot:__construct in /home/ebargello/domains/e-bargello.com/public_html/index.php:10
5
Rain\Tpl\NotFoundException
/Libs/View.php127
4
App\Libs\View checkTemplate
/Libs/View.php57
3
App\Libs\View draw
/Controllers/Index.php306
2
App\Controllers\Index brands
/vendor/illuminate/routing/Controller.php54
1
Illuminate\Routing\Controller callAction
/Libs/Boot.php47
0
App\Libs\Boot __construct
/index.php10
                $templateDirectory .= $templateBasedir;
                $templateFilepath = $templateDirectory . $templateName . '.' . $this->config['tpl_ext'];
 
 
                $parsedTemplateFilepath = $this->config['cache_dir'] . $templateName . "." . md5($templateDirectory . serialize($this->config['checksum'])) . '.rtpl.php';
 
                // For check templates are exists
                if (file_exists($templateFilepath)) {
                    $isFileNotExist = false;
                    break;
                }
            }
        }
        if ($isFileNotExist === true && file_exists($this->config["default_tpl_dir"] . $template . '.' . $this->config["tpl_ext"])) {
            $templateFilepath = $this->config["default_tpl_dir"] . $template . '.' . $this->config["tpl_ext"];
            $isFileNotExist = false;
        }
        // if the template doesn't exsist throw an error
        if ($isFileNotExist === true) {
            $e = new Tpl\NotFoundException('Template ' . $templateName . ' not found!');
            throw $e->templateFile($templateFilepath);
        }
 
        // Compile the template if the original has been updated
        if ($this->config['debug'] || !file_exists($parsedTemplateFilepath) || (filemtime($parsedTemplateFilepath) < filemtime($templateFilepath))) {
            $parser = new Tpl\Parser($this->config, static::$plugins, static::$registered_tags);
            $parser->compileFile($templateName, $templateBasedir, $templateDirectory, $templateFilepath, $parsedTemplateFilepath);
        }
        return $parsedTemplateFilepath;
    }
 
    public function __call(string $method, array $args = [])
    {
        return call_user_func_array(
            [$this->tpl, $method],
            $args
        );
    }
    public function addNamespace($namespace, $path)
    {
Arguments
  1. "Template index not found!"
    
    public function __construct()
    {
        $this->tpl               = new Tpl();
 
 
        self::$conf["cache_dir"] = config('view.compiled') . DIRECTORY_SEPARATOR;
        Tpl::configure(self::$conf);
    }
    public function configure($key, $value)
    {
        self::$conf[$key] =  $value;
    }
    public function draw($templateFilePath, $toString = false)
    {
        extract($this->tpl->var);
        // Merge local and static configurations
        $this->config = $this->objectConf + self::$conf;
 
        ob_start();
        require $this->checkTemplate($templateFilePath);
        $html = ob_get_clean();
 
        // Execute plugins, before_parse
        $context = $this->getPlugins()->createContext(array(
            'code' => $html,
            'conf' => $this->config,
        ));
        $this->getPlugins()->run('afterDraw', $context);
        $html = $context->code;
        if ($toString) {
            return $html;
        } else {
            echo $html;
        }
    }
    protected static function getPlugins()
    {
        return static::$plugins
            ?: static::$plugins = new Tpl\PluginContainer();
    }
    // }
 
    public function brands($id = null)
    {
 
        $brand = Cache::remember("brand.$id", now()->addWeek(), function () use ($id) {
            return Brand::with('seolink')->findOrfail($id);
        });
 
        $categories = Category::getall()->whereIn('id', $brand->category_id)->where('parent', 0)->where('status', 1)->sortBy('row');
 
 
        $slider42 = Slider::getAllSlider()->where('id', 42)->where('status', 1)->first()->pictures;
        $this->view->assign('main_slider', $slider42);
 
        $this->view->assign('title', ($brand['seo_title']) ? $brand['seo_title'] : $brand['name']);
        $this->view->assign('keywords', $brand["seo_keywords"]);
        $this->view->assign('description', $brand["seo_desc"]);
        $this->view->assign('categories', $categories);
        $this->view->assign('content', $this->view->draw('brands/index', true));
        $this->view->draw('index');
    }
    public function brandsAll()
    {
        $this->blockSet();
        $this->view->assign('title', trans('system.markalar'));
        $this->view->assign('keywords', Config::get('settings.seo_keywords'));
        $this->view->assign('description', Config::get('settings.seo_desc'));
        $this->view->assign('brand_main_list', $this->brand_main_list(false));
        $view = $this->view->draw('brandsall', true);
        $this->view->assign('cat_open', true);
        if (!isset($_COOKIE["cp"]) && Config::get('settings.cp_status')) {
            $this->view->assign('cp', Config::get('settings.cp_shortdetail'));
            setcookie('cp', true, time() + (86400 * 30));
        }
        if (Config::get('settings.shipmentcd_status')) {
            $this->view->assign('shipmentcd', array(Config::get('settings.shipmentcd_status'), explode(":", Config::get('settings.shipmentcd_time'), 2), str_replace('{$gun}', '<strong class="day"></strong>', Config::get('settings.shipmentcd_text')), Config::get('settings.shipmentcd_fg'), Config::get('settings.shipmentcd_bg')));
        }
        $this->view->assign("shipment_days", Config::get('settings.shipment_days'));
 
    /**
     * Get the middleware assigned to the controller.
     *
     * @return array
     */
    public function getMiddleware()
    {
        return $this->middleware;
    }
 
    /**
     * Execute an action on the controller.
     *
     * @param  string  $method
     * @param  array  $parameters
     * @return \Symfony\Component\HttpFoundation\Response
     */
    public function callAction($method, $parameters)
    {
        return $this->{$method}(...array_values($parameters));
    }
 
    /**
     * Handle calls to missing methods on the controller.
     *
     * @param  string  $method
     * @param  array  $parameters
     * @return mixed
     *
     * @throws \BadMethodCallException
     */
    public function __call($method, $parameters)
    {
        throw new BadMethodCallException(sprintf(
            'Method %s::%s does not exist.', static::class, $method
        ));
    }
}
 
        if (!Request::has('url')) {
            define('SUPERPOS', 'main');
            define('SUPERMODEL', null);
            $controller =  app(\App\Controllers\Index::class);
 
            $controller->loadModel('index');
 
            return $controller->main();
        } else {
            $url = Request::input('url');
 
            $url = seoUrl($url);
            define('SUPERPOS', $url["method"]);
            define('SUPERMODEL', $url["model"]);
 
            if (Reflector::isCallable([$url["controller"], $url["method"]])) {
                $controller = app($url["controller"]);
                $controller->loadModel($url["model"]);
 
                return $controller->callAction($url["method"], (array)$url["parameters"]);
            } else {
                $controller =  app(\App\Controllers\Index::class);
                $controller->loadModel('index');
                return $controller->callAction('_error', []);
            }
        }
    }
    private function app()
    {
        parent::__construct(ROOT_PATH);
        $this->app->instance('request', \Illuminate\Http\Request::capture());
        $this->app->singleton(
            \Illuminate\Contracts\Debug\ExceptionHandler::class,
            \App\Exceptions\Handler::class
        );
        $this->app->bootstrapWith([
            \App\Classes\Bootstrap\LoadEnvironmentVariables::class,
            \App\Classes\Bootstrap\LoadConfiguration::class,
            \App\Classes\Bootstrap\HandleExceptions::class,
            \App\Classes\Bootstrap\RegisterFacades::class,
<?php
 
require_once 'config.php';
 
require_once __DIR__ . '/vendor/autoload.php';
 
use App\Libs\Boot;
use Illuminate\Support\Facades\DB;
 
$app = new Boot();
// dump(DB::getQueryLog());
// dd(number_format(microtime(true) - START, 2) . 'sn', readableSize(MEMORY));
 

Environment & details:

Key Value
url
"bargello.html"
sort
"pASC"
empty
empty
empty
Key Value
referrer
"www.e-bargello.com"
lang
"tr"
Key Value
USER
"ebargello"
HOME
"/home/ebargello"
SCRIPT_NAME
"/index.php"
REQUEST_URI
"/bargello.html?sort=pASC"
QUERY_STRING
"url=bargello%2ehtml&sort=pASC"
REQUEST_METHOD
"GET"
SERVER_PROTOCOL
"HTTP/1.0"
GATEWAY_INTERFACE
"CGI/1.1"
REDIRECT_QUERY_STRING
"url=bargello%2ehtml&sort=pASC"
REDIRECT_URL
"/bargello.html"
REMOTE_PORT
"38962"
SCRIPT_FILENAME
"/home/ebargello/domains/e-bargello.com/private_html/index.php"
SERVER_ADMIN
"webmaster@e-bargello.com"
CONTEXT_DOCUMENT_ROOT
"/home/ebargello/domains/e-bargello.com/private_html"
CONTEXT_PREFIX
""
REQUEST_SCHEME
"https"
DOCUMENT_ROOT
"/home/ebargello/domains/e-bargello.com/private_html"
REMOTE_ADDR
"54.146.154.243"
SERVER_PORT
"443"
SERVER_ADDR
"93.186.118.112"
SERVER_NAME
"www.e-bargello.com"
SERVER_SOFTWARE
"Apache/2"
SERVER_SIGNATURE
""
PATH
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin"
HTTP_USER_AGENT
"claudebot"
HTTP_ACCEPT
"*/*"
HTTP_CONNECTION
"close"
HTTP_X_FORWARDED_FOR
"54.146.154.243"
HTTP_HOST
"www.e-bargello.com"
HTTP_X_ACCEL_INTERNAL
"/nginx_static_files"
proxy-nokeepalive
"1"
HTTPS
"on"
UNIQUE_ID
"ZgWHNaqStzljdIcE836JpAAAAGY"
REDIRECT_STATUS
"200"
REDIRECT_HTTPS
"on"
REDIRECT_UNIQUE_ID
"ZgWHNaqStzljdIcE836JpAAAAGY"
FCGI_ROLE
"RESPONDER"
PHP_SELF
"/index.php"
REQUEST_TIME_FLOAT
1711638325.655
REQUEST_TIME
1711638325
APP_URL
"https://www.e-bargello.com/"
APP_ENV
"local"
APP_DEBUG
"true"
APP_NAME
"Bargello"
LOG_CHANNEL
"daily"
LOG_LEVEL
"debug"
CACHE_DRIVER
"file"
SESSION_DOMAIN
".e-bargello.com"
DB_HOST
"localhost"
DB_PORT
"3306"
DB_DATABASE
"ebargello_db"
DB_USERNAME
"ebargello_db"
DB_PASSWORD
"gnJqnVUJNQkfn3MzeBwR"
OLD_DB_HOST
"localhost"
OLD_DB_DATABASE
"barges_db"
OLD_DB_USERNAME
"barges_db"
OLD_DB_PASSWORD
"12qwaszx"
MAIL_MAILER
"smtp"
MAIL_HOST
"smtp.yandex.com.tr"
MAIL_PORT
"587"
MAIL_USERNAME
"smtp@eticaretport.com"
MAIL_PASSWORD
"Jh0FlZwge"
MAIL_ENCRYPTION
"tls"
MAIL_FROM_ADDRESS
"smtp@eticaretport.com"
MAIL_FROM_NAME
"Bargello"
Key Value
APP_URL
"https://www.e-bargello.com/"
APP_ENV
"local"
APP_DEBUG
"true"
APP_NAME
"Bargello"
LOG_CHANNEL
"daily"
LOG_LEVEL
"debug"
CACHE_DRIVER
"file"
SESSION_DOMAIN
".e-bargello.com"
DB_HOST
"localhost"
DB_PORT
"3306"
DB_DATABASE
"ebargello_db"
DB_USERNAME
"ebargello_db"
DB_PASSWORD
"gnJqnVUJNQkfn3MzeBwR"
OLD_DB_HOST
"localhost"
OLD_DB_DATABASE
"barges_db"
OLD_DB_USERNAME
"barges_db"
OLD_DB_PASSWORD
"12qwaszx"
MAIL_MAILER
"smtp"
MAIL_HOST
"smtp.yandex.com.tr"
MAIL_PORT
"587"
MAIL_USERNAME
"smtp@eticaretport.com"
MAIL_PASSWORD
"Jh0FlZwge"
MAIL_ENCRYPTION
"tls"
MAIL_FROM_ADDRESS
"smtp@eticaretport.com"
MAIL_FROM_NAME
"Bargello"
0. Whoops\Handler\PrettyPageHandler