Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG  Not logged in ELOG logo
icon1.gif   Subst on Reply, posted by Emiliano Gabrielli on Fri Jul 8 10:52:36 2005 
    icon1.gif   Re: Subst on Reply, posted by Stefan Ritt on Fri Jul 8 22:38:51 2005 
       icon1.gif   Re: Subst on Reply, posted by Emiliano Gabrielli on Sat Jul 9 14:13:10 2005 
Message ID: 1248     Entry time: Fri Jul 8 22:38:51 2005     In reply to: 1242     Reply to this: 1249
Icon: Entry  Author: Stefan Ritt  Author Email: stefan.ritt@psi.ch 
Category: Bug report  OS: All  ELOG Version: 2.6beta2 
Subject: Re: Subst on Reply 

Emiliano Gabrielli wrote:
the "subst on reply" parameter seems to correctly work only on the first reply..
since the second reply has the author locked to the one having replyed the first time.

Here is my config:
; preset author and email
Preset Author                 = $short_name
Preset Author Email           = $user_email
Subst on reply Author         = $short_name
Subst on reply Author Email   = $user_email
Subst on reply subject        = Re: $subject

; these attributes cannot be changed
Locked Attributes             = Author, Author Email
Fixed Attributes Reply        = Subject

My poor man solution is for now to allow everyone to change the author (unlock the field ..)


You need
Preset on reply Author = $short_name
. Subst is supposed to work after a submission, Preset before you open the edit mask. See this forum. If you reply to this entry, your name appears as the Author even if it's locked. Here is the config:
Preset Author = $long_name
Preset Author Email = $user_email
Preset on reply Author = $long_name
Preset on reply Author Email = $user_email
Locked Attributes = Author

The Subst can be used for your image category thing. So instead using
Display Category = $category <img src="icons/$category.png" border="0">

you can use
Subst Category = $category <img src="icons/$category.png" border="0">

which physically rewrites the category. This is probably not what you want, but take it as an example. We use it in one place to replace a user name by a link to our internal telephonbook searching for this username, so if one clicks on the user, one ends up in the user's telephonebook entry.
ELOG V3.1.5-fe60aaf