Archives de la liste a​i​d​e​@p​a​h​e​k​o​.c​l​o​u​d​

Version 0.9.8, erreur Notice: Undefined variable: current_parent

Laurent Mélé

01/09/2020 10:44:23

Bonjour,

J'ai essayé d'installer garradin en version 0.9.8 (j'ai actuellement une 
version 0.8.2) qui tourne afin d'évaluer les fonctionnalités.

A l'installation tout se passe bien, quand j'initialise la base, j'ai 
tout de suite après un message d'erreur PHP :


    Notice: Undefined variable: current_parent

Je suis en apache et php 7.4 mon ancienne version tourne correctement 
sur cette version.

Quelqu'un a déjà eu ce cas ?


Merci à vous




Détail de l'erreur : (chemin réel caché par BLAH)


  \__/
  (xx)
//||\\


  Une erreur s'est produite


  PHP error


    Notice: Undefined variable: current_parent


      in
      .../cache/compiled/*551cc339dffb032ec13cddb85bc8e12b07f26e43.tpl.php.tmp*:/99/

|*95* *96* </li> *97* <?php if($session->canAccess('membres', 
Membres::DROIT_ACCES)): //#66?> *98* _*99* <li class="member list<?php 
if($current == 'membres'): //#67?> current<?php elseif($current_parent 
== 'membres'): //#67?> current_parent<?php endif;
//#67?>"><a 
href="<?php echo self::escape($admin_url, $this->escape_type); 
//#67?>membres/"><b class="icn">????</b><i>
Membres</i></a>_ *100* <?php 
if($session->canAccess('membres', Membres::DROIT_ECRITURE)): //#68?> 
*101* *102* <ul> *103* <li class="member new<?php if($current == 
'membres/ajouter'): //#70?> current<?php endif; //#70?>"><a
href="<?php 
echo self::escape($admin_url, $this->escape_type); 
//#70?>membres/ajouter.php">Ajouter</a></li> |


      in .../include/lib/KD2/*Smartyer.php*:/646/


        → include /(1 arg.)/

0 	

string(71)
".../cache/compiled/551cc339dffb032ec13cddb85bc8e12b07f26e43.tpl.php.tmp"

|*642*	extract($this->variables, EXTR_REFS); *643* *644*	ob_start(); 
*645* _*646*	include $this->compiled_template_path . '.tmp';_ *647* 
*648*	$out = ob_get_clean(); *649*	} *650*	catch (\Exception $e) |


      in .../include/lib/KD2/*Smartyer.php*:/395/


        → KD2\Smartyer->compile /(0 arg.)/

|*391*	$time = @filemtime($this->compiled_template_path); *392* *393*	if 
(!$time || (!is_null($this->template_path) && 
filemtime($this->template_path) > $time)) *394*	{ _*395*	return 
$this->compile();_ *396*	} *397* *398*	extract($this->variables, 
EXTR_REFS); *399* |


      in .../include/lib/KD2/*Smartyer.php*:/334/


        → KD2\Smartyer->fetch /(1 arg.)/

$template 	

NULL

|*330*	* @return Smartyer *331*	*/ *332*	public function 
display($template = null) *333*	{ _*334*	echo $this->fetch($template);_ 
*335*	return $this; *336*	} *337* *338*	/** |


      in
      .../cache/compiled/*8f8700facaf5c6fff6b03e835a389446be1858a6.tpl.php.tmp*:/5/


        → KD2\Smartyer->display /(0 arg.)/

|*1*<?php /* Compiled from 
/BLAH/htdocs/garradinnew/templates/admin/index.tpl - 2020-09-01 08:35:05 
UTC */ *2*namespace Garradin; *3*if (!isset($this) || !is_object($this) 
|| (!($this instanceof \KD2\Smartyer) && !is_subclass_of($this, 
'\KD2\Smartyer', true))) { die("Wrong call context."); } if 
(!isset($_i)) { $_i = []; } if (!isset($_blocks)) { $_blocks = []; } 
?><?php $_s = new \KD2\Smartyer('admin/_head.tpl', $this); 
$_s->assign(array_merge(get_defined_vars(), ['title' => 
$this->modifiers['args']("Bonjour %s !", $this->_magicVar($user,
array ( 
*4* 0 => 'identite', _*5*))), 'current' => 'home',
])); $_s->display(); 
unset($_s); //#1?>_ *6* *7* *8*<?php echo $banniere; //#3?> *9* |


      in .../include/lib/KD2/*Smartyer.php*:/646/


        → include /(1 arg.)/

0 	

string(71)
".../cache/compiled/8f8700facaf5c6fff6b03e835a389446be1858a6.tpl.php.tmp"

|*642*	extract($this->variables, EXTR_REFS); *643* *644*	ob_start(); 
*645* _*646*	include $this->compiled_template_path . '.tmp';_ *647* 
*648*	$out = ob_get_clean(); *649*	} *650*	catch (\Exception $e) |


      in .../include/lib/KD2/*Smartyer.php*:/395/


        → KD2\Smartyer->compile /(0 arg.)/

|*391*	$time = @filemtime($this->compiled_template_path); *392* *393*	if 
(!$time || (!is_null($this->template_path) && 
filemtime($this->template_path) > $time)) *394*	{ _*395*	return 
$this->compile();_ *396*	} *397* *398*	extract($this->variables, 
EXTR_REFS); *399* |


      in .../include/lib/KD2/*Smartyer.php*:/350/


        → KD2\Smartyer->fetch /(0 arg.)/

|*346*	{ *347*	// Compatibility with legacy Smarty calls *348*	if 
(!is_null($template)) *349*	{ _*350*	return (new Smartyer($template, 
$this))->fetch();_ *351*	} *352* *353*	if (is_null($this->compiled_dir)) 
*354*	{ |


      in .../include/lib/KD2/*Smartyer.php*:/334/


        → KD2\Smartyer->fetch /(1 arg.)/

$template 	

string(15) "admin/index.tpl"

|*330*	* @return Smartyer *331*	*/ *332*	public function 
display($template = null) *333*	{ _*334*	echo $this->fetch($template);_ 
*335*	return $this; *336*	} *337* *338*	/** |


      in .../www/admin/*index.php*:/35/


        → KD2\Smartyer->display /(1 arg.)/

$template 	

string(15) "admin/index.tpl"

|*31*$tpl->assign('custom_css', ['wiki.css']); *32* 
*33*$tpl->assign('banniere', Plugin::fireSignal('accueil.banniere',

['user' => $user, 'session' => $session])); *34* 
_*35*$tpl->display('admin/index.tpl');_ *36*flush(); *37* *38*// Si pas 
de cron on réalise les tâches automatisées à ce moment-là *39*// c'est 
pas idéal mais mieux que rien |


    Context

id 	9ychdjxp
date 	2020-09-01T10:35:05+02:00
os 	Linux
language 	PHP 7.4.9
environment 	development
php_sapi 	cgi-fcgi
remote_ip 	141.101.69.121
http_method 	GET
files_sent 	array(0) { }
rootDirectory 	/BLAH/htdocs/garradinnew
garradin_data_root 	/BLAH/htdocs/garradinnew
garradin_version 	0.9.8
url 	https://www.tir-mauperthuis.fr/garradinnew/admin/

Re: Version 0.9.8, erreur Notice: Undefined variable: current_parent

grd32@free.fr

01/09/2020 11:31:43

Oui j'ai la même erreur et je n'ai pas trouvé de solution

Envoyé depuis mon mobile ????

________________________________
From: Laurent Mélé <lme@crashdump.net>
Sent: Tuesday, September 1, 2020 10:43:43 AM
To: aide@garradin.eu <aide@garradin.eu>
Subject: [garradin] Version 0.9.8, erreur Notice: Undefined variable: current_parent


Bonjour,

J'ai essayé d'installer garradin en version 0.9.8 (j'ai actuellement une
version 0.8.2) qui tourne afin d'évaluer les fonctionnalités.

A l'installation tout se passe bien, quand j'initialise la base, j'ai tout
de suite après un message d'erreur PHP :

Notice: Undefined variable: current_parent

Je suis en apache et php 7.4 mon ancienne version tourne correctement sur cette version.

Quelqu'un a déjà eu ce cas ?


Merci à vous




Détail de l'erreur : (chemin réel caché par BLAH)


 \__/
 (xx)
//||\\

Une erreur s'est produite
PHP error
Notice: Undefined variable: current_parent
in .../cache/compiled/551cc339dffb032ec13cddb85bc8e12b07f26e43.tpl.php.tmp:99

95
96        </li>
97        <?php if($session->canAccess('membres', Membres::DROIT_ACCES)):
//#66?>
98
99            <li class="member list<?php if($current == 'membres'):
//#67?> current<?php elseif($current_parent == 'membres'): //#67?>
current_parent<?php endif; //#67?>"><a href="<?php echo
self::escape($admin_url, $this->escape_type); //#67?>membres/"><b
class="icn">????</b><i> Membres</i></a>
100            <?php if($session->canAccess('membres',
Membres::DROIT_ECRITURE)): //#68?>
101
102            <ul>
103                <li class="member new<?php if($current ==
'membres/ajouter'): //#70?> current<?php endif; //#70?>"><a
href="<?php echo self::escape($admin_url, $this->escape_type);
//#70?>membres/ajouter.php">Ajouter</a></li>


in .../include/lib/KD2/Smartyer.php:646
→ include (1 arg.)
0

string(71)
".../cache/compiled/551cc339dffb032ec13cddb85bc8e12b07f26e43.tpl.php.tmp"

642                     extract($this->variables, EXTR_REFS);
643
644                     ob_start();
645
646                     include $this->compiled_template_path . '.tmp';
647
648                     $out = ob_get_clean();
649             }
650             catch (\Exception $e)


in .../include/lib/KD2/Smartyer.php:395
→ KD2\Smartyer->compile (0 arg.)

391             $time = @filemtime($this->compiled_template_path);
392
393             if (!$time || (!is_null($this->template_path) &&
filemtime($this->template_path) > $time))
394             {
395                     return $this->compile();
396             }
397
398             extract($this->variables, EXTR_REFS);
399


in .../include/lib/KD2/Smartyer.php:334
→ KD2\Smartyer->fetch (1 arg.)
$template

NULL

330      * @return Smartyer
331      */
332     public function display($template = null)
333     {
334             echo $this->fetch($template);
335             return $this;
336     }
337
338     /**


in .../cache/compiled/8f8700facaf5c6fff6b03e835a389446be1858a6.tpl.php.tmp:5
→ KD2\Smartyer->display (0 arg.)

1<?php /* Compiled from /BLAH/htdocs/garradinnew/templates/admin/index.tpl - 2020-09-01
08:35:05 UTC */
2namespace Garradin;
3if (!isset($this) || !is_object($this) || (!($this instanceof \KD2\Smartyer) &&
!is_subclass_of($this, '\KD2\Smartyer', true))) { die("Wrong call
context."); } if (!isset($_i)) { $_i = []; } if (!isset($_blocks)) { $_blocks = []; }
?><?php $_s = new \KD2\Smartyer('admin/_head.tpl', $this);
$_s->assign(array_merge(get_defined_vars(), ['title' =>
$this->modifiers['args']("Bonjour %s !", $this->_magicVar($user,
array (
4  0 => 'identite',
5))), 'current' => 'home', ])); $_s->display(); unset($_s);
//#1?>
6
7
8<?php echo $banniere; //#3?>
9


in .../include/lib/KD2/Smartyer.php:646
→ include (1 arg.)
0

string(71)
".../cache/compiled/8f8700facaf5c6fff6b03e835a389446be1858a6.tpl.php.tmp"

642                     extract($this->variables, EXTR_REFS);
643
644                     ob_start();
645
646                     include $this->compiled_template_path . '.tmp';
647
648                     $out = ob_get_clean();
649             }
650             catch (\Exception $e)


in .../include/lib/KD2/Smartyer.php:395
→ KD2\Smartyer->compile (0 arg.)

391             $time = @filemtime($this->compiled_template_path);
392
393             if (!$time || (!is_null($this->template_path) &&
filemtime($this->template_path) > $time))
394             {
395                     return $this->compile();
396             }
397
398             extract($this->variables, EXTR_REFS);
399


in .../include/lib/KD2/Smartyer.php:350
→ KD2\Smartyer->fetch (0 arg.)

346     {
347             // Compatibility with legacy Smarty calls
348             if (!is_null($template))
349             {
350                     return (new Smartyer($template, $this))->fetch();
351             }
352
353             if (is_null($this->compiled_dir))
354             {


in .../include/lib/KD2/Smartyer.php:334
→ KD2\Smartyer->fetch (1 arg.)
$template

string(15) "admin/index.tpl"

330      * @return Smartyer
331      */
332     public function display($template = null)
333     {
334             echo $this->fetch($template);
335             return $this;
336     }
337
338     /**


in .../www/admin/index.php:35
→ KD2\Smartyer->display (1 arg.)
$template

string(15) "admin/index.tpl"

31$tpl->assign('custom_css', ['wiki.css']);
32
33$tpl->assign('banniere', Plugin::fireSignal('accueil.banniere',
['user' => $user, 'session' => $session]));
34
35$tpl->display('admin/index.tpl');
36flush();
37
38// Si pas de cron on réalise les tâches automatisées à ce moment-là
39// c'est pas idéal mais mieux que rien


Context
id      9ychdjxp
date    2020-09-01T10:35:05+02:00
os      Linux
language        PHP 7.4.9
environment     development
php_sapi        cgi-fcgi
remote_ip       141.101.69.121
http_method     GET
files_sent      array(0) { }
rootDirectory   /BLAH/htdocs/garradinnew
garradin_data_root      /BLAH/htdocs/garradinnew
garradin_version        0.9.8
url     https://www.tir-mauperthuis.fr/garradinnew/admin/

Re: Version 0.9.8, erreur Notice: Undefined variable: current_parent

BohwaZ/Garradin

01/09/2020 12:19:27

Hello,

je n'ai fait que mettre à jour une dépendance qui avait un bug, mais ce
n'était pas forcément la bonne méthode en fait de le faire sans mettre
à jour le numéro de version.

Vous trouverez donc une version 0.9.8.1 sur le site, qui forcera
l'effacement du cache, ce qui devrait régler les soucis rencontrés je
pense.

Désolé de ce contretemps.

A plus.

Re: Version 0.9.8, erreur Notice: Undefined variable: current_parent

Laurent Mélé

02/09/2020 13:53:56

Bonjour,


Cela fonctionne avec cette nouvelle version.


Merci !

Le 01/09/2020 à 12:19, BohwaZ/Garradin a écrit :
> Hello,
>
> je n'ai fait que mettre à jour une dépendance qui avait un bug, mais ce
> n'était pas forcément la bonne méthode en fait de le faire sans mettre
> à jour le numéro de version.
>
> Vous trouverez donc une version 0.9.8.1 sur le site, qui forcera
> l'effacement du cache, ce qui devrait régler les soucis rencontrés je
> pense.
>
> Désolé de ce contretemps.
>
> A plus.
>

Re: Version 0.9.8, erreur Notice: Undefined variable: current_parent

grd32@free.fr

02/09/2020 14:56:20

OK maintenant ça fonctionne bien.
Merci

Envoyé depuis mon mobile ????

________________________________
From: Laurent Mélé <lme@crashdump.net>
Sent: Wednesday, September 2, 2020 1:53:24 PM
To: aide@garradin.eu <aide@garradin.eu>
Subject: Re: [garradin] Version 0.9.8, erreur Notice: Undefined variable: current_parent

Bonjour,


Cela fonctionne avec cette nouvelle version.


Merci !

Le 01/09/2020 à 12:19, BohwaZ/Garradin a écrit :

> Hello,

>

> je n'ai fait que mettre à jour une dépendance qui avait un bug, mais
ce

> n'était pas forcément la bonne méthode en fait de le faire sans
mettre

> à jour le numéro de version.

>

> Vous trouverez donc une version 0.9.8.1 sur le site, qui forcera

> l'effacement du cache, ce qui devrait régler les soucis rencontrés je

> pense.

>

> Désolé de ce contretemps.

>

> A plus.

>


--
. ____
 / ___|  Liste d'entraide des utilisateurs de Garradin
| |  _   http://garradin.eu/
| |_| |
 \____|  Désinscription : http://garradin.eu/aide/