Forum OpenACS Q&A: Response to Ybos Content Managemnet errors

Posted by Janine Ohmer on
Do you know if the OpenACS site running this has the ad_user_content_map filter turned on?

Yes, we do seem to have that filter turned on (I'm basing this on empirical evidence, since I can see in the log that the ad-user-content-map.tcl script is being sourced and filters are being activated).

When I use cm_return_file for an HTML file, the ad_user_content_map proc dies because it is trying to grab a db handle when one is already in use. It looks like this filter is running before cm_file_return finishes and releases the db handle. Again, I really don;t need this either way, I am just curious to see if its only me!

It's not just you (at least, I don't think so). I never use cm_return_file, so if there was a problem with it I wouldn't have seen it. In fact, I didn't know it existed until I just went and looked for it!

See, I started using the Ybos code right when it was first released, when there was no documentation yet. So I learned my own way of doing things, and since it works for me, I haven't needed to change. The content on Liz Krueger's site is all served out of templates, and the templates are sourced by cm_serve_section, which is in tcl/cm-defs.tcl. I can say with some confidence that this approach works well. :)

Obviously we could have done more testing of the parts we don't use - sorry you are running into all these problems. If you send me diffs of your fixes, I will include them and re-release the tarball.