Pagina 1 van 1

themplate.php

Geplaatst: 06 aug 2004, 19:44
door superman5000
ik heb nadat ik wat gerommelt heb in de codes ;)
een gekke foutmelding gekregen.
ik zouw niet weten waar aan het kan liggen.
maar mischien kunnen julie mij even helpen.

Code: Selecteer alles

Parse error: parse error, unexpected $ in /home/paulv/public_html/phpBB3/includes/template.php(127) : eval()'d code on line 177
dat is dus de foutmelding.

dit is een stukje van themplate.php

Code: Selecteer alles

lijn:158	/**
lijn:159	 * Block-level variable assignment. Adds a new block iteration with the given
lijn:160	 * variable assignments. Note that this should only be called once per block
lijn:161	 * iteration.
lijn:162	 */
lijn:163	function assign_block_vars($blockname, $vararray)
lijn:164	{
lijn:165		if (strstr($blockname, '.'))
lijn:166		{
lijn:167			// Nested block.
lijn:168			$blocks = explode('.', $blockname);
lijn:169			$blockcount = sizeof($blocks) - 1;
lijn:170			$str = '$this->_tpldata';
lijn:171			for ($i = 0; $i < $blockcount; $i++)
lijn:172			{
lijn:173			$str .= '[\'' . $blocks[$i] . '.\']';
lijn:174				eval('$lastiteration = sizeof(' . $str . ') - 1;');
lijn:175				$str .= '[' . $lastiteration . ']';
lijn:176			}
lijn:177			// Now we add the block that we're actually assigning to.
lijn:178			// We're adding a new iteration to this block with the given
lijn:179			// variable assignments.
lijn:180			$str .= '[\'' . $blocks[$blockcount] . '.\'][] = $vararray;';
lijn:181
lijn:182			// Now we evaluate this assignment we've built up.
lijn:183			eval($str);
lijn:184		}
lijn:185		else
lijn:186		{
lijn:187			// Top-level block.
lijn:188			// Add a new iteration to this block with the variable assignments
lijn:189		// we were given.
lijn:190			$this->_tpldata[$blockname . '.'][] = $vararray;
alvast bedankt voor de hulp. :bier:

Geplaatst: 06 aug 2004, 20:30
door mosymuis
Dit is géén error in template.php, maar in de TPL van de pagina waar de error ontstaat. Daar heb je een <!-- BLOCK --> niet goed afgesloten.

Geplaatst: 06 aug 2004, 21:52
door superman5000
Dank je wel.
had een typo gemaakt :wink:
:thumb: :thumb: