When does cb_story get called with respect to $variable replacement?
Mukund Lakshman <[email protected]> Sun, 11 Jul 2010 23:00:33 -0500
| Newsgroups | gmane.comp.web.pyblosxom.devel |
|---|---|
| Message-ID | <[email protected]> |
(Hi all, this is my first mailing list post so please be gentle...)
I've got a simple cb_story function that grabs the short filename ('fn') from the entry and stores it in a variable $filename. Here's what I've got:
def cb_story(args):
request = args["request"]
filename = args["entry"].get("fn")
data = request.get_data()
data["filename"] = filename
My story template also includes "The name of the file is $filename" so we can view it after each entry. For my example, I've got three posts file1, file2, and file3 rendered in ascending order (so file1 is at the top of the page). I thought each story would be labeled with its correct filename, but each post is labeled with the filename of the *previous* story. So the page displays as,
File1
The name of the file is (blank)
File2
The name of the file is file1
File3
The name of the file is file2
What am I doing wrong? Thanks in advance!
- Mukund
------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first