Sorry if this msg was sent twice...

----- Original Message -----
From: "Emiliano" <[EMAIL PROTECTED]>
To: "Midgard Mailing List" <[EMAIL PROTECTED]>
Sent: Friday, May 26, 2000 1:41 PM
Subject: Re: [midgard] blobs, files and images


>
> On Fri, 26 May 2000, Vanja Bertalan wrote:
>
> blobs (aka attachments) are more self-contained and can be attached to any
> record type. Methods are available to serve out blobs including their
> headers, and blobs attached to page records are served directly by
> mod_midgard (depending on needed authorization of course).

What does it mean when you say 'served directly'?

David's sample code for blobifying was a good guide
 http://marc.theaimsgroup.com/?l=midgard-dev&m=95684800219327&w=2 ), though
a few additional examples would be great too.
I'm feeling xtreme stupid on this, but maybe it's just common 'bed? don't
recognize the word... + who stole my coffe...' syndrom :)
Anyway, these are things I was thinking about:
- letting user download a blob. This should be easy, serveattachment should
do it, right?
- display blob in html page, say image.gif is stored as attachment. Same as
above, figured it out now...
html page says ie.:
<img src="/?displayimage=&(some_blob.id);">
and code-global says (doesn't have to be code-global, can be separate page
or whatever):
if ($displayimage) {
  mgd_serve_attachment($displayimage);
  exit;
}
When on this, what about getattachment in addition to listattachments so we
don't have to walk though all of them if we know what to search for?

Another thing, methods $object-><methodname> are not equal to functions
mgd_<methodname>. Underscore has to be put between words, ie.
mgd_serve_attachment(int id); and not mgd_serveattachment(int id);

So far so good, hopefully... I love blobs :)

And, is there a way to get a hold of location field of a blob? Say I wanted
to pass that to perl which would read the blob from the disk, parse it, and
send the result back...

> Emile
>
> --
Vanja 'found my coffe' Bertalan



--
This is The Midgard Project's mailing list. For more information,
please visit the project's web site at http://www.midgard-project.org

To unsubscribe the list, send an empty email message to address
[EMAIL PROTECTED]

Reply via email to