Thanks for your help!
Sorry, that i didnt answer immediatly.
I changed the code for the img-page.The int(argv[0]) didn't work in my page
so I changed it to:
if (($argc > 0) and ($id = $argv[0])) { ...}
But now I'm wondering, if there is a way to list just the images belonging
to one article.
thx georg
----- Original Message -----
From: "Sergei Dolmatov" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, November 01, 2002 2:35 AM
Subject: Re: [midgard-user] topic - attachments HELP
> On Thu, Oct 31, 2002 at 01:26:35PM +0100, Georg Berner wrote:
> > I want to refer to my topic.attachments by <img src="...">. What "path"
do i
> > have to use. Should i refer to them by id or by name?
>
> Well, short instruction.
>
> 1. For example, your host's prefix: $prefix = "/myhost"
> 2. You have active page 'img' under your root page, so it's uri is
> '/myhost/img'
> 3. It's style is emty - so only <[ROOT]> in style and <[ROOT]> contains
only
> <[content]>
> 4. Content of this page (for example):
>
> <?php
> if (($argc > 0) and ($id = int(argv[0]))) {
> mgd_serve_attachment($id);
> }
> ?>
> 5. So you can now refer to this attachments as:
> <img src="&(prefix);/img/&(attachment.id);">
> And you can even add there attachment.name, so names for saving would be
> more usual :)
>
> If you edit this script a little, you can refer to attachments by name
too.
> Looks like you have to send topic id too.
>
> --
> Regards,
> Sergei Dolmatov.
> ---
> As of next Thursday, UNIX will be flushed in favor of TOPS-10.
> Please update your programs.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]