Personnaly, I've never been able to use the "persistent_variable". (Ezpublish 3.6.4) Posted a thread about this a few weeks ago, no answers yet.
If you're line view is called within a loop, I suggest that you use a counter and each time you iterates you pass it to your template. Something like this for example.
{def $my_counter=0}
{foreach $my_line_array as $my_line}
{node_view_gui view=line content_node=$my_line my_counter=$my_counter} {*You pass your variable to your line.tpl, making it available into the template view. *}
{set scope=global $my_counter=inc( $my_counter )} {*Here you increment your counter *}
{/foreach}
And then you can easily retrive the $my_counter var into your line.tpl or in the overrride.
Actually this apporach works just fine, but the case is that my line_log.tpl is not beeing called manually so it does not solve my problem with the persistent variable not beeing available in the line.tpl override.
I`ll go for your solution with the manual fetch and make an override for folder.tpl instead.
Thanks for your quick answer.
------------------------------------
Gunnar Birkeland http://www.enternett.no