Re: Entry Format
will guaraldi <[email protected]>
| Newsgroups | gmane.comp.web.pyblosxom.user |
|---|---|
| Message-ID | <[email protected]> |
You want to build an entryparser and connect it to a file extension like ".nb" (your initials) or something similarly unique. However, you can do everything it appears you're trying to do right now with the existing default entry parser. It supports "meta-data". So your entry below would look like this: Test Entry #Date 2004-08-24 #Renderer Plain #Etc Blah <p>This is a test pyblosxom entry</p> Having said that, there are some minor problems. Currently we don't support storing the mtime in the entry itself. That's something you'll have to do with another plugin and it gets complex. Check the recent mailing list archives for ideas on how to deal with that issue. Also, you can't (and shouldn't be) switching the renderer for each entry. I'm guessing you might mean template, in which case you can do: #template_name name (where "name" is replaced by another template name other than story [don't do the flavour extension]) and that'll set the template for that specific entry. Also, if you have the comments plugin installed, you can do: #nocomments yes and that'll prevent people from adding comments to that entry. Hope that helps-- /will On Wed, 8 Sep 2004, Nathan Bullock wrote: > > Currently each entry for pyblosxom is a text file where the first line > is the title of the entry and the rest is the body of the entry. > > If I wanted to change this would this be accomplished > through a plugin, or the actual pyblosxom code. > > For example I want each entry file to look like this: > > Title="Test Entry" > Date="2004-08-24" # this is optional > Renderer="Plain" # this is optional > Etc="Blah" # other optional entries > Entry=""" > <p>This is a test pyblosxom entry</p> > """ > > > This would allow me to store the date actually in the entry and allow > further customization of individual entries. (Plus I don't think it is > any more difficult to read or learn, possibly easier.) Plus it could be > parsed by python itself, not by a regex style parser or some other > custom solution. > > Nathan Bullock ------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click