Bugs item #580446, was opened at 2002-07-11 23:52
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=403611&aid=580446&group_id=31885
Category: Template
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: Error using parse(append true AND false)
Initial Comment:
If youre working with nested blocks and parse a block
inside an other block using append=false AND
append=true alternatly the output is wrong.
1.Step
set_var("foo","foobar")
parse("target","handle",false)
parse("main_block","MAIN_BLOCK",true)
output:
foobar
2. Step
$array=array("test1","test2","test3")
while($bar) = each($array){
set_var("foo",$bar)
parse("target","handle",true)
}
parse("main_block","MAIN_BLOCK",true)
output:
foobar
test1
test2
test3
My Workaround:
I'am using a flag $reset which is by default false. If i add
a row into a block with append=false i change this flag
to true.
Depending on this flag and after parsing main_block i'm
emptying the varvalue $target by set_var("target","")
If somebodys got a better Idea... ;-)
----------------------------------------------------------------------
Comment By: Nobody/Anonymous (nobody)
Date: 2002-07-11 23:54
Message:
Logged In: NO
Sorry, i forgot...
my Name is Frank Schenk and my Mail is fr...@yp...
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=403611&aid=580446&group_id=31885
|