/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
* @param array $bindings
* @param \Closure $callback
* @return mixed
*
* @throws \Illuminate\Database\QueryException
*/
protected function runQueryCallback($query, $bindings, Closure $callback)
{
// To execute the statement, we'll simply call the callback, which will actually
// run the SQL against the PDO connection. Then we can calculate the time it
// took to execute and log the query SQL, bindings and time in our memory.
try {
return $callback($query, $bindings);
}
// If an exception occurs when attempting to run a query, we'll format the error
// message to include the bindings with SQL, which will make this exception a
// lot more helpful to the developer instead of just the database's errors.
catch (Exception $e) {
throw new QueryException(
$query, $this->prepareBindings($bindings), $e
);
}
}
/**
* Log a query in the connection's query log.
*
* @param string $query
* @param array $bindings
* @param float|null $time
* @return void
*/
public function logQuery($query, $bindings, $time = null)
{
$this->event(new QueryExecuted($query, $bindings, $time, $this));
if ($this->loggingQueries) {
$this->queryLog[] = compact('query', 'bindings', 'time');
}
Arguments
"SQLSTATE[HY000]: General error: 1615 Prepared statement needs to be re-prepared (SQL: select * from `noticies_tipus` where `pare_id` is null and `lang` = ca order by `ordre` asc) (View: /var/www/virtual/escolajoan23.com/htdocs/custom/views/template/parts/header.blade.php)"
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/view/Engines/PhpEngine.php
/**
* Get the evaluated contents of the view at the given path.
*
* @param string $path
* @param array $data
* @return string
*/
protected function evaluatePath($path, $data)
{
$obLevel = ob_get_level();
ob_start();
// We'll evaluate the contents of the view inside a try/catch block so we can
// flush out any stray output that might get out before an error occurs or
// an exception is thrown. This prevents any partial views from leaking.
try {
$this->files->getRequire($path, $data);
} catch (Throwable $e) {
$this->handleViewException($e, $obLevel);
}
return ltrim(ob_get_clean());
}
/**
* Handle a view exception.
*
* @param \Throwable $e
* @param int $obLevel
* @return void
*
* @throws \Throwable
*/
protected function handleViewException(Throwable $e, $obLevel)
{
while (ob_get_level() > $obLevel) {
ob_end_clean();
}
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
* @param array $bindings
* @param \Closure $callback
* @return mixed
*
* @throws \Illuminate\Database\QueryException
*/
protected function runQueryCallback($query, $bindings, Closure $callback)
{
// To execute the statement, we'll simply call the callback, which will actually
// run the SQL against the PDO connection. Then we can calculate the time it
// took to execute and log the query SQL, bindings and time in our memory.
try {
return $callback($query, $bindings);
}
// If an exception occurs when attempting to run a query, we'll format the error
// message to include the bindings with SQL, which will make this exception a
// lot more helpful to the developer instead of just the database's errors.
catch (Exception $e) {
throw new QueryException(
$query, $this->prepareBindings($bindings), $e
);
}
}
/**
* Log a query in the connection's query log.
*
* @param string $query
* @param array $bindings
* @param float|null $time
* @return void
*/
public function logQuery($query, $bindings, $time = null)
{
$this->event(new QueryExecuted($query, $bindings, $time, $this));
if ($this->loggingQueries) {
$this->queryLog[] = compact('query', 'bindings', 'time');
}
Arguments
"SQLSTATE[HY000]: General error: 1615 Prepared statement needs to be re-prepared (SQL: select * from `noticies_tipus` where `pare_id` is null and `lang` = ca order by `ordre` asc)"
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
* @param bool $useReadPdo
* @return array
*/
public function select($query, $bindings = [], $useReadPdo = true)
{
return $this->run($query, $bindings, function ($query, $bindings) use ($useReadPdo) {
if ($this->pretending()) {
return [];
}
// For select statements, we'll simply execute the query and return an array
// of the database result set. Each element in the array will be a single
// row from the database table, and will either be an array or objects.
$statement = $this->prepared(
$this->getPdoForSelect($useReadPdo)->prepare($query)
);
$this->bindValues($statement, $this->prepareBindings($bindings));
$statement->execute();
return $statement->fetchAll();
});
}
/**
* Run a select statement against the database and returns a generator.
*
* @param string $query
* @param array $bindings
* @param bool $useReadPdo
* @return \Generator
*/
public function cursor($query, $bindings = [], $useReadPdo = true)
{
$statement = $this->run($query, $bindings, function ($query, $bindings) use ($useReadPdo) {
if ($this->pretending()) {
return [];
}
Arguments
"SQLSTATE[HY000]: General error: 1615 Prepared statement needs to be re-prepared"
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
* @param bool $useReadPdo
* @return array
*/
public function select($query, $bindings = [], $useReadPdo = true)
{
return $this->run($query, $bindings, function ($query, $bindings) use ($useReadPdo) {
if ($this->pretending()) {
return [];
}
// For select statements, we'll simply execute the query and return an array
// of the database result set. Each element in the array will be a single
// row from the database table, and will either be an array or objects.
$statement = $this->prepared(
$this->getPdoForSelect($useReadPdo)->prepare($query)
);
$this->bindValues($statement, $this->prepareBindings($bindings));
$statement->execute();
return $statement->fetchAll();
});
}
/**
* Run a select statement against the database and returns a generator.
*
* @param string $query
* @param array $bindings
* @param bool $useReadPdo
* @return \Generator
*/
public function cursor($query, $bindings = [], $useReadPdo = true)
{
$statement = $this->run($query, $bindings, function ($query, $bindings) use ($useReadPdo) {
if ($this->pretending()) {
return [];
}
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
return $result;
}
/**
* Run a SQL statement.
*
* @param string $query
* @param array $bindings
* @param \Closure $callback
* @return mixed
*
* @throws \Illuminate\Database\QueryException
*/
protected function runQueryCallback($query, $bindings, Closure $callback)
{
// To execute the statement, we'll simply call the callback, which will actually
// run the SQL against the PDO connection. Then we can calculate the time it
// took to execute and log the query SQL, bindings and time in our memory.
try {
return $callback($query, $bindings);
}
// If an exception occurs when attempting to run a query, we'll format the error
// message to include the bindings with SQL, which will make this exception a
// lot more helpful to the developer instead of just the database's errors.
catch (Exception $e) {
throw new QueryException(
$query, $this->prepareBindings($bindings), $e
);
}
}
/**
* Log a query in the connection's query log.
*
* @param string $query
* @param array $bindings
* @param float|null $time
* @return void
*/
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
* @param \Closure $callback
* @return mixed
*
* @throws \Illuminate\Database\QueryException
*/
protected function run($query, $bindings, Closure $callback)
{
foreach ($this->beforeExecutingCallbacks as $beforeExecutingCallback) {
$beforeExecutingCallback($query, $bindings, $this);
}
$this->reconnectIfMissingConnection();
$start = microtime(true);
// Here we will run this query. If an exception occurs we'll determine if it was
// caused by a connection that has been lost. If that is the cause, we'll try
// to re-establish connection and re-run the query with a fresh connection.
try {
$result = $this->runQueryCallback($query, $bindings, $callback);
} catch (QueryException $e) {
$result = $this->handleQueryException(
$e, $query, $bindings, $callback
);
}
// Once we have run the query we will calculate the time that it took to run and
// then log the query, bindings, and execution time so we will report them on
// the event that the developer needs them. We'll log time in milliseconds.
$this->logQuery(
$query, $bindings, $this->getElapsedTime($start)
);
return $result;
}
/**
* Run a SQL statement.
*
* @param string $query
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Connection.php
public function select($query, $bindings = [], $useReadPdo = true)
{
return $this->run($query, $bindings, function ($query, $bindings) use ($useReadPdo) {
if ($this->pretending()) {
return [];
}
// For select statements, we'll simply execute the query and return an array
// of the database result set. Each element in the array will be a single
// row from the database table, and will either be an array or objects.
$statement = $this->prepared(
$this->getPdoForSelect($useReadPdo)->prepare($query)
);
$this->bindValues($statement, $this->prepareBindings($bindings));
$statement->execute();
return $statement->fetchAll();
});
}
/**
* Run a select statement against the database and returns a generator.
*
* @param string $query
* @param array $bindings
* @param bool $useReadPdo
* @return \Generator
*/
public function cursor($query, $bindings = [], $useReadPdo = true)
{
$statement = $this->run($query, $bindings, function ($query, $bindings) use ($useReadPdo) {
if ($this->pretending()) {
return [];
}
// First we will create a statement for the query. Then, we will set the fetch
// mode and prepare the bindings for the query. Once that's done we will be
// ready to execute the query against the database and return the cursor.
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Query/Builder.php
*
* @param array|string $columns
* @return \Illuminate\Support\Collection
*/
public function get($columns = ['*'])
{
return collect($this->onceWithColumns(Arr::wrap($columns), function () {
return $this->processor->processSelect($this, $this->runSelect());
}));
}
/**
* Run the query as a "select" statement against the connection.
*
* @return array
*/
protected function runSelect()
{
return $this->connection->select(
$this->toSql(), $this->getBindings(), ! $this->useWritePdo
);
}
/**
* Paginate the given query into a simple paginator.
*
* @param int $perPage
* @param array $columns
* @param string $pageName
* @param int|null $page
* @return \Illuminate\Contracts\Pagination\LengthAwarePaginator
*/
public function paginate($perPage = 15, $columns = ['*'], $pageName = 'page', $page = null)
{
$page = $page ?: Paginator::resolveCurrentPage($pageName);
$total = $this->getCountForPagination();
$results = $total ? $this->forPage($page, $perPage)->get($columns) : collect();
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Query/Builder.php
* @param string $column
* @return mixed
*/
public function value($column)
{
$result = (array) $this->first([$column]);
return count($result) > 0 ? reset($result) : null;
}
/**
* Execute the query as a "select" statement.
*
* @param array|string $columns
* @return \Illuminate\Support\Collection
*/
public function get($columns = ['*'])
{
return collect($this->onceWithColumns(Arr::wrap($columns), function () {
return $this->processor->processSelect($this, $this->runSelect());
}));
}
/**
* Run the query as a "select" statement against the connection.
*
* @return array
*/
protected function runSelect()
{
return $this->connection->select(
$this->toSql(), $this->getBindings(), ! $this->useWritePdo
);
}
/**
* Paginate the given query into a simple paginator.
*
* @param int $perPage
* @param array $columns
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Query/Builder.php
}
/**
* Execute the given callback while selecting the given columns.
*
* After running the callback, the columns are reset to the original value.
*
* @param array $columns
* @param callable $callback
* @return mixed
*/
protected function onceWithColumns($columns, $callback)
{
$original = $this->columns;
if (is_null($original)) {
$this->columns = $columns;
}
$result = $callback();
$this->columns = $original;
return $result;
}
/**
* Insert new records into the database.
*
* @param array $values
* @return bool
*/
public function insert(array $values)
{
// Since every insert gets treated like a batch insert, we will make sure the
// bindings are structured in a way that is convenient when building these
// inserts statements by verifying these elements are actually an array.
if (empty($values)) {
return true;
}
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Query/Builder.php
* @return mixed
*/
public function value($column)
{
$result = (array) $this->first([$column]);
return count($result) > 0 ? reset($result) : null;
}
/**
* Execute the query as a "select" statement.
*
* @param array|string $columns
* @return \Illuminate\Support\Collection
*/
public function get($columns = ['*'])
{
return collect($this->onceWithColumns(Arr::wrap($columns), function () {
return $this->processor->processSelect($this, $this->runSelect());
}));
}
/**
* Run the query as a "select" statement against the connection.
*
* @return array
*/
protected function runSelect()
{
return $this->connection->select(
$this->toSql(), $this->getBindings(), ! $this->useWritePdo
);
}
/**
* Paginate the given query into a simple paginator.
*
* @param int $perPage
* @param array $columns
* @param string $pageName
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Eloquent/Builder.php
// If we actually found models we will also eager load any relationships that
// have been specified as needing to be eager loaded, which will solve the
// n+1 query issue for the developers to avoid running a lot of queries.
if (count($models = $builder->getModels($columns)) > 0) {
$models = $builder->eagerLoadRelations($models);
}
return $builder->getModel()->newCollection($models);
}
/**
* Get the hydrated models without eager loading.
*
* @param array|string $columns
* @return \Illuminate\Database\Eloquent\Model[]|static[]
*/
public function getModels($columns = ['*'])
{
return $this->model->hydrate(
$this->query->get($columns)->all()
)->all();
}
/**
* Eager load the relationships for the models.
*
* @param array $models
* @return array
*/
public function eagerLoadRelations(array $models)
{
foreach ($this->eagerLoad as $name => $constraints) {
// For nested eager loads we'll skip loading them here and they will be set as an
// eager load on the query to retrieve the relation so that they will be eager
// loaded on that query, because that is where they get hydrated as models.
if (strpos($name, '.') === false) {
$models = $this->eagerLoadRelation($models, $name, $constraints);
}
}
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/database/Eloquent/Builder.php
*/
public function valueOrFail($column)
{
return $this->firstOrFail([$column])->{Str::afterLast($column, '.')};
}
/**
* Execute the query as a "select" statement.
*
* @param array|string $columns
* @return \Illuminate\Database\Eloquent\Collection|static[]
*/
public function get($columns = ['*'])
{
$builder = $this->applyScopes();
// If we actually found models we will also eager load any relationships that
// have been specified as needing to be eager loaded, which will solve the
// n+1 query issue for the developers to avoid running a lot of queries.
if (count($models = $builder->getModels($columns)) > 0) {
$models = $builder->eagerLoadRelations($models);
}
return $builder->getModel()->newCollection($models);
}
/**
* Get the hydrated models without eager loading.
*
* @param array|string $columns
* @return \Illuminate\Database\Eloquent\Model[]|static[]
*/
public function getModels($columns = ['*'])
{
return $this->model->hydrate(
$this->query->get($columns)->all()
)->all();
}
/**
/var/www/virtual/escolajoan23.com/htdocs/common/application/helpers/my_menu_helper.php
break;
case 'tradicional':
default:
show_categories($item, $categories, $base_url, $current_module, 'productes');
break;
}
//show_categories($item, $categories, $base_url, $current_module, 'productes');
break;
case 'galeries':
//Mostrem l'item principal i les categories
$CI->load->model('galeries/Mgaleries');
$categories = $CI->Mgaleries->getAllTipus(array('lang' => $lang));
$base_url = getURL('galeries');
show_categories($item, $categories, $base_url, $current_module);
break;
case 'noticies':
//Mostrem l'item principal i les categories
$categories = NoticiaTipus::lang($lang)->with('tipus')->where('pare_id', null)->orderBy('ordre', 'ASC')->get();
$base_url = getURL('noticies');
showItemMenuWithCategories($item, $categories, $base_url, $current_module);
break;
default:
//Mostrem l'item i els seus fills
echo '<li ' . ($item->getChildren() ? ' class="has-dropdown"' : '') . '>';
if($item->getChildren()) echo '<div class="mobnav-subarrow"><i class="fa fa-plus"></i></div>';
$selected = (ltrim($item->url, '/') == $lang . '/' . $last_segment ? true : false);
//Comprovem si està actiu
if($item->actiu) echo '<a ' . ($selected ? ' class="selected"' : '') . ' href="' . base_url() . ltrim($item->url, '/') . '" target="' . $item->target . '">';
else{
//Comprovem si no està actiu, i vol redireccionar al fill
if($item->redirect_primer_fill){
$item_actiu = _get_primer_fill_actiu($item->getChildren());
}
/var/www/virtual/escolajoan23.com/htdocs/common/application/helpers/my_menu_helper.php
<?php
use App\NoticiaTipus;
if (!defined('BASEPATH'))
exit('No direct script access allowed');
function create_menu(){
$CI = & get_instance();
$CI->load->model('menu/Mmenu');
//Agafem el menú en forma de nodes (només amb els nodes amb els permisos que podem veure)
$where = array('lang' => $CI->config->item('language_abbr'), 'visible' => 1, 'embedded !=' => 1);
$items = $CI->Mmenu->getItems($where);
$nodes = $CI->Mnodes->getArbreNodes( $items ); //A partir del resultat generem tota la classe d'arbre
if (!empty($nodes)) {
show_item_menu($nodes->getChildren(), 'principal');
}
}
function _mostrar_fills($list, $baseURL, $tipus = null){
foreach ($list as $item){
echo '<li ' . (($item->getChildren()) ? ' class="has-dropdown"' : '') . '>';
if($item->getChildren()) echo '<div class="mobnav-subarrow"><i class="fa fa-plus"></i></div>';
$link_categoria = $baseURL . '/categoria/' . $item->titol_url;
echo '<a href="' . $link_categoria . '">' . $item->titol . '</a>';
if($item->getChildren()){
echo '<ul>';
_mostrar_fills($item->getChildren(), $baseURL, $tipus);
echo '</ul>';
}
echo '</li>';
}
}
/var/www/virtual/escolajoan23.com/htdocs/cache/5867dd8e9d70d001277e209af43a3e28da6dfc33.php
<div id="header-menu" class="container-fluid bg-menu d-flex align-items-center">
<a href="<?= base_url() . $lang; ?>" id="logo" class="d-none d-md-flex align-items-center me-0 me-md-5">
<img src="<?= base_url('img/logo-escola.jpg'); ?>" alt="Col·legi Sant Pau">
</a>
<div class="w-100 d-flex align-items-center justify-content-end justify-content-xl-between">
<nav id="menu">
<div class="d-xl-none">
<div class="d-flex justify-content-md-end align-items-center justify-content-start align-content-sm-center box_menu">
<a id="mobnav-btn" class="text-white d-inline-block d-flex align-items-center">
<i class="fa fa-bars"></i>
</a>
</div>
</div>
<ul class="sf-menu text-left w-100 d-xl-flex justify-content-between">
<?php
//Mostrem tot el menú
create_menu();
?>
</ul>
</nav>
<div class="acces-amagat d-flex gap-3">
<a href="https://escolajoan23.clickedu.eu/user.php?action=login" target="_blank" class="btn btn-outline-primary btn-rounded me-2"><i class="fas fa-sign-in me-1"></i> Clickedu</a>
<a href="https://educaciodigital.cat/esc-joan23-bonavista/moodle/login/index.php" target="_blank" class="btn btn-outline-primary btn-rounded"><i class="fas fa-sign-in me-1"></i> Moodle</a>
</div>
</div>
</div>
</div>
</header>
<?php /**PATH /var/www/virtual/escolajoan23.com/htdocs/custom/views/template/parts/header.blade.php ENDPATH**/ ?>
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/filesystem/Filesystem.php
/**
* Get the returned value of a file.
*
* @param string $path
* @param array $data
* @return mixed
*
* @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
*/
public function getRequire($path, array $data = [])
{
if ($this->isFile($path)) {
$__path = $path;
$__data = $data;
return (static function () use ($__path, $__data) {
extract($__data, EXTR_SKIP);
return require $__path;
})();
}
throw new FileNotFoundException("File does not exist at path {$path}.");
}
/**
* Require the given file once.
*
* @param string $path
* @param array $data
* @return mixed
*
* @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
*/
public function requireOnce($path, array $data = [])
{
if ($this->isFile($path)) {
$__path = $path;
$__data = $data;
Arguments
"/var/www/virtual/escolajoan23.com/htdocs/cache/5867dd8e9d70d001277e209af43a3e28da6dfc33.php"
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/filesystem/Filesystem.php
/**
* Get the returned value of a file.
*
* @param string $path
* @param array $data
* @return mixed
*
* @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
*/
public function getRequire($path, array $data = [])
{
if ($this->isFile($path)) {
$__path = $path;
$__data = $data;
return (static function () use ($__path, $__data) {
extract($__data, EXTR_SKIP);
return require $__path;
})();
}
throw new FileNotFoundException("File does not exist at path {$path}.");
}
/**
* Require the given file once.
*
* @param string $path
* @param array $data
* @return mixed
*
* @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
*/
public function requireOnce($path, array $data = [])
{
if ($this->isFile($path)) {
$__path = $path;
$__data = $data;
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/view/Engines/PhpEngine.php
}
/**
* Get the evaluated contents of the view at the given path.
*
* @param string $path
* @param array $data
* @return string
*/
protected function evaluatePath($path, $data)
{
$obLevel = ob_get_level();
ob_start();
// We'll evaluate the contents of the view inside a try/catch block so we can
// flush out any stray output that might get out before an error occurs or
// an exception is thrown. This prevents any partial views from leaking.
try {
$this->files->getRequire($path, $data);
} catch (Throwable $e) {
$this->handleViewException($e, $obLevel);
}
return ltrim(ob_get_clean());
}
/**
* Handle a view exception.
*
* @param \Throwable $e
* @param int $obLevel
* @return void
*
* @throws \Throwable
*/
protected function handleViewException(Throwable $e, $obLevel)
{
while (ob_get_level() > $obLevel) {
ob_end_clean();
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/view/Engines/CompilerEngine.php
*
* @param string $path
* @param array $data
* @return string
*/
public function get($path, array $data = [])
{
$this->lastCompiled[] = $path;
// If this given view has expired, which means it has simply been edited since
// it was last compiled, we will re-compile the views so we can evaluate a
// fresh copy of the view. We'll pass the compiler the path of the view.
if ($this->compiler->isExpired($path)) {
$this->compiler->compile($path);
}
// Once we have the path to the compiled file, we will evaluate the paths with
// typical PHP just like any other templates. We also keep a stack of views
// which have been rendered for right exception messages to be generated.
$results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
array_pop($this->lastCompiled);
return $results;
}
/**
* Handle a view exception.
*
* @param \Throwable $e
* @param int $obLevel
* @return void
*
* @throws \Throwable
*/
protected function handleViewException(Throwable $e, $obLevel)
{
$e = new ViewException($this->getMessage($e), 0, 1, $e->getFile(), $e->getLine(), $e);
parent::handleViewException($e, $obLevel);
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/view/View.php
$this->factory->callComposer($this);
$contents = $this->getContents();
// Once we've finished rendering the view, we'll decrement the render count
// so that each sections get flushed out next time a view is created and
// no old sections are staying around in the memory of an environment.
$this->factory->decrementRender();
return $contents;
}
/**
* Get the evaluated contents of the view.
*
* @return string
*/
protected function getContents()
{
return $this->engine->get($this->path, $this->gatherData());
}
/**
* Get the data bound to the view instance.
*
* @return array
*/
public function gatherData()
{
$data = array_merge($this->factory->getShared(), $this->data);
foreach ($data as $key => $value) {
if ($value instanceof Renderable) {
$data[$key] = $value->render();
}
}
return $data;
}
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/view/View.php
throw $e;
}
}
/**
* Get the contents of the view instance.
*
* @return string
*/
protected function renderContents()
{
// We will keep track of the amount of views being rendered so we can flush
// the section after the complete rendering operation is done. This will
// clear out the sections for any separate views that may be rendered.
$this->factory->incrementRender();
$this->factory->callComposer($this);
$contents = $this->getContents();
// Once we've finished rendering the view, we'll decrement the render count
// so that each sections get flushed out next time a view is created and
// no old sections are staying around in the memory of an environment.
$this->factory->decrementRender();
return $contents;
}
/**
* Get the evaluated contents of the view.
*
* @return string
*/
protected function getContents()
{
return $this->engine->get($this->path, $this->gatherData());
}
/**
/var/www/virtual/escolajoan23.com/htdocs/vendor/illuminate/view/View.php
$this->view = $view;
$this->path = $path;
$this->engine = $engine;
$this->factory = $factory;
$this->data = $data instanceof Arrayable ? $data->toArray() : (array) $data;
}
/**
* Get the string contents of the view.
*
* @param callable|null $callback
* @return string
*
* @throws \Throwable
*/
public function render(callable $callback = null)
{
try {
$contents = $this->renderContents();
$response = isset($callback) ? $callback($this, $contents) : null;
// Once we have the contents of the view, we will flush the sections if we are
// done rendering all views so that there is nothing left hanging over when
// another view gets rendered in the future by the application developer.
$this->factory->flushStateIfDoneRendering();
return ! is_null($response) ? $response : $contents;
} catch (Throwable $e) {
$this->factory->flushState();
throw $e;
}
}
/**
* Get the contents of the view instance.
*
* @return string
/var/www/virtual/escolajoan23.com/htdocs/common/application/helpers/utility_helper.php
unset($parts[0]);
}
$view = implode('/', $parts);
}
// Comprovem si existeix la vista
if (is_file($path . $view)) {
$path_view = $path;
}
if(empty($path_view)) $path_view = VIEWPATH;
$path_cache = FCPATH . '/cache/';
// Triem ".blade" del nom
$view = substr($view, 0, strpos($view, ".blade.php"));
$blade = new Blade($path_view, $path_cache);
return $blade->make($view, $data)->render();
}
function get_columnes_bootstrap_from_number($number)
{
switch ($number) {
case 1:
return 'col-12';
case 2:
return 'col-md-6';
case 3:
return 'col-md-4';
case 4:
return 'col-md-3';
case 6:
return 'col-md-2';
case 12:
return 'col-md-1';
}
}
/var/www/virtual/escolajoan23.com/htdocs/common/application/core/MY_Loader.php
if (is_file($customPath . $path . $file_ext)) {
return array($customPath . $path, $file);
}
return array(FALSE, $file);
}
private function isBlade($view)
{
if (!strpos($view, '.blade')) return false;
return true;
}
private function showBlade($path, $view, $vars)
{
$arr = $this->_ci_cached_vars;
$arr['CI'] = $this;
// Combinem les variables de CI amb les que passem nosaltres
$composite = array_merge($arr, $vars);
return show_blade_view($path, $view, $composite);
}
/** Load a module view **/
public function view($view, $vars = array(), $return = FALSE)
{
if ($this->isBlade($view)) {
$view = $view . '.php';
}
// ** COMPROVEM SI ÉS UNA VISTA DE MÒDUL **
// Agafem el path de la vista si existeix dins application/modules...
// També mira si existeix abans a la carpeta "custom" de l'arrel perquè hem afegit el path a $config['modules_locations']
list($path, $_view) = Modules::find($view, $this->_module, 'views/');
if ($path != FALSE) {
$this->_ci_view_paths = array($path => TRUE) + $this->_ci_view_paths;
$view = $_view;
}
/var/www/virtual/escolajoan23.com/htdocs/common/application/core/MY_Loader.php
list($path, $_view) = Modules::find($view, $this->_module, 'views/');
if ($path != FALSE) {
$this->_ci_view_paths = array($path => TRUE) + $this->_ci_view_paths;
$view = $_view;
}
/** NO ÉS VISTA DE MÒDUL **/
if(empty($path)){
// Comprovem si existeix la vista fora d'un mòdul (per exemple els "inc") a la carpeta "custom" per sobresciure
list($path, $_view) = $this->customView($view);
}
if ($path !== FALSE) {
$this->_ci_view_paths = array($path => TRUE) + $this->_ci_view_paths;
$view = $_view;
}
if ($this->isBlade($view)) {
echo $this->showBlade($path, $view, $vars);
return;
}
if (method_exists($this, '_ci_object_to_array')) {
return $this->_ci_load(
array('_ci_view' => $view, '_ci_vars' => $this->_ci_object_to_array($vars), '_ci_return' => $return)
);
} else {
return $this->_ci_load(
array('_ci_view' => $view, '_ci_vars' => $this->_ci_prepare_view_vars($vars), '_ci_return' => $return)
);
}
}
}
/var/www/virtual/escolajoan23.com/htdocs/custom/views/template.php
echo '<meta name="keywords" content="' . $this->config->item('domain_name') . '" />';
}
if (!empty($metas['meta_tags'])) {
echo html_entity_decode($metas['meta_tags']);
}
?>
<meta name="author" content="entornweb.com"/>
<!-- Estils pròpis compilats -->
<link rel="stylesheet" href="<?= base_url(); ?>css/app.css">
<link rel="stylesheet" href="<?= base_url(); ?>css/custom.css">
<script src="https://ewcookiesctl.com/cookies.js" id="ckew" data-ckewid="CZ5K9RHVYYQVNNRP976I"></script>
</head>
<body class="d-flex flex-column">
<?php $this->load->view('template/parts/header.blade'); ?>
<main>
<!-- spinner -->
<div class="spinner">
<div class="box_spinner">
<i class="fa-solid fa-circle-notch fa-4x fa-spin text-primary"></i>
</div>
</div>
<?php $this->load->view($main); ?>
</main>
<?php
$this->load->view('footer/footer'); ?>
<div href="#" class="back-to-top"><i class="fa fa-angle-up"></i></div>
<script src="https://vjs.zencdn.net/7.20.3/video.min.js"></script>
/var/www/virtual/escolajoan23.com/htdocs/common/application/third_party/MX/Loader.php
if( ! file_exists($_ci_path)) $_ci_path = '';
}
if (empty($_ci_path))
show_error('Unable to load the requested file: '.$_ci_file);
if (isset($_ci_vars))
$this->_ci_cached_vars = array_merge($this->_ci_cached_vars, (array) $_ci_vars);
extract($this->_ci_cached_vars);
ob_start();
if ((bool) @ini_get('short_open_tag') === FALSE && CI::$APP->config->item('rewrite_short_tags') == TRUE)
{
echo eval('?>'.preg_replace("/;*\s*\?>/", "; ?>", str_replace('<?=', '<?php echo ', file_get_contents($_ci_path))));
}
else
{
include($_ci_path);
}
log_message('debug', 'File loaded: '.$_ci_path);
if ($_ci_return == TRUE) return ob_get_clean();
if (ob_get_level() > $this->_ci_ob_level + 1)
{
ob_end_flush();
}
else
{
CI::$APP->output->append_output(ob_get_clean());
}
}
/** Autoload module items **/
public function _autoloader($autoload)
{
$path = FALSE;
Arguments
"/var/www/virtual/escolajoan23.com/htdocs/custom/views/template.php"
/var/www/virtual/escolajoan23.com/htdocs/common/application/core/MY_Loader.php
list($path, $_view) = $this->customView($view);
}
if ($path !== FALSE) {
$this->_ci_view_paths = array($path => TRUE) + $this->_ci_view_paths;
$view = $_view;
}
if ($this->isBlade($view)) {
echo $this->showBlade($path, $view, $vars);
return;
}
if (method_exists($this, '_ci_object_to_array')) {
return $this->_ci_load(
array('_ci_view' => $view, '_ci_vars' => $this->_ci_object_to_array($vars), '_ci_return' => $return)
);
} else {
return $this->_ci_load(
array('_ci_view' => $view, '_ci_vars' => $this->_ci_prepare_view_vars($vars), '_ci_return' => $return)
);
}
}
}
/var/www/virtual/escolajoan23.com/htdocs/common/application/modules/error404/controllers/Error404.php
http_response_code(!empty($config['error404_codi_resposta']) ? $config['error404_codi_resposta'] : 404);
if (!empty($config['error404_url'])) {
$url = $config['error404_url'];
if (empty(parse_url($config['error404_url'], PHP_URL_SCHEME))) {
$url = base_url() . $url;
}
$responseCode = $this->get_http_response_code($url);
if ($responseCode == "200" || $responseCode == "301") {
$this->showPageFromUrl($url);
}
}
// Mostrem la pàgina d'error per defecte
$data['config'] = $config;
$data['lang'] = $this->config->item('language_abbr');
$data['main'] = '404';
$this->load->view('template', $data);
}
private function showPageFromUrl($url)
{
$htmlPage = file_get_contents($url);
if ($htmlPage) {
echo $htmlPage;
die();
}
}
private function get_http_response_code($url)
{
$headers = get_headers($url);
return substr($headers[0], 9, 3);
}
}
/var/www/virtual/escolajoan23.com/htdocs/common/system/core/CodeIgniter.php
* ------------------------------------------------------
*/
// Mark a start point so we can benchmark the controller
$BM->mark('controller_execution_time_( '.$class.' / '.$method.' )_start');
$CI = new $class();
/*
* ------------------------------------------------------
* Is there a "post_controller_constructor" hook?
* ------------------------------------------------------
*/
$EXT->call_hook('post_controller_constructor');
/*
* ------------------------------------------------------
* Call the requested method
* ------------------------------------------------------
*/
call_user_func_array(array(&$CI, $method), $params);
// Mark a benchmark end point
$BM->mark('controller_execution_time_( '.$class.' / '.$method.' )_end');
/*
* ------------------------------------------------------
* Is there a "post_controller" hook?
* ------------------------------------------------------
*/
$EXT->call_hook('post_controller');
/*
* ------------------------------------------------------
* Send the final rendered output to the browser
* ------------------------------------------------------
*/
if ($EXT->call_hook('display_override') === FALSE)
{
$OUT->_display();
}
/var/www/virtual/escolajoan23.com/htdocs/index.php
DIRECTORY_SEPARATOR.DIRECTORY_SEPARATOR
);
}
else
{
header('HTTP/1.1 503 Service Unavailable.', TRUE, 503);
echo 'Your view folder path does not appear to be set correctly. Please open the following file and correct this: '.SELF;
exit(3); // EXIT_CONFIG
}
define('VIEWPATH', $view_folder.DIRECTORY_SEPARATOR);
/*
* --------------------------------------------------------------------
* LOAD THE BOOTSTRAP FILE
* --------------------------------------------------------------------
*
* And away we go...
*/
require_once BASEPATH.'core/CodeIgniter.php';
Arguments
"/var/www/virtual/escolajoan23.com/htdocs/common/system/core/CodeIgniter.php"