Forum OpenACS Development: Re: Media package ideas

Collapse
14: Re: Media package ideas (response to 12)
Posted by Tom Jackson on

The main requirement of the package would be to provide a simple method for the developer to allow users to attach media to other database objects, and to make it easy to display these attachments as links or inline content.

I'll prepare a requirements document to explain the datamodel.

The reason to attach to something other than acs_objects is that, personally I use a lot of support tables that don't need to be acs_objects, which would benefit from media attachments.

For example, some developer might use the list of the states in grouping users. When listing the users, they might want to have a little icon with the shape of the state. The developer could use the media package to associate the icons with the state data. It should also be possible to package this data up for general use.

Another user might be reading the forums and want to provide a link from a post to another thread, or to some relevant document. The forum template could be modified to include a simple tag that would provide a link to the media UI so a user could add the link, or other document.

I might want to allow users to include multiple pictures of themselves, or about subjects of interest. They should be able to visit their workspace and find a link to let them add new photos.

I'm guessing that if I used the CR, my media table id column would have to reference cr_revisions instead of acs_objects. What I am not sure about is that if I have many different media types, how will the other attributes be stored, since they can't all be in the media table?