Lukas and Avi,
Thanks for the quick responses, but something is not working for me.
When I follow Lukas's point that when a new link *my fine picture* is created, one can then upload the data to define the resource. When I do this (using a .jpg, .png image) and keep 'emedded' enabled, the image link is created but it is not inlined to the page. FWIW, going to the page holding the resources shows the mime type as 'unknown'.
Have I missed something blindingly obvious?
Happy new year,
Michael
Lukas Renggli renggli@student.unibe.ch wrote:
Is there a way to have embedded images in a SmallWiki page? All I seem to be able to do is to set up a link to the image.
yes this is the way to go: simply create a link from your wiki-page to the resource and the image should be inlined automatically. As an example you might want to check out this page:
http://kilana.unibe.ch:9090/ese2003gruppen-smallwikis/ sureshockwriters/
Hm. That shows a link to *ssw-image* as if it were a wiki page - is there some way to upload and name an image, then?
Yes, but as it points to a resource it is rendered differently according to its mime-type: that means if it is an image an <img>, if it is a movie an <object>, etc. is emitted.
When creating a new link *The New Image* to a non existant structure in SmallWiki at first the link doesn't point to anything. However on the html-page a list with all the possible structures (depending of the security configuration for the current user not all possibliites might be shown) will be rendered and the user can choose what he wants to point this link to. In the given example one would click on 'Resource' and an upload-dialog will be presented where the user specifies the file to upload. When hitting ok, a new resource named 'The New Image' is created and the user is brought back to the original page displaying now the image now inlined.
Hi Michael,
Have I missed something blindingly obvious?
I don't think so, this is a bug in the Squeak implementation of SmallWiki. I've checked the archives of the SmallWiki mailing-list and attached two mails of the previousely mentioned topic. Unfortunately I don't know if this has been fixed already or is still outstanding. For further information it would be the best to ask the Squeak porters ( Chris Burkert).
Cheers, Lukas
PS: Happy new year, too! Sorry to have replayed to your posting that slow, I just noticed it today by accident. I should probably set-up some of the filtering/highlighting capabilites of my news-client ... ;)
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
From: chris AT chrisburkert.de Subject: Re: [Q][Bug] Action class SWResourceEdit Date: December 7, 2003 20:53:50 GMT+01:00 To: smallwiki AT iam.unibe.ch
Hi Hannes,
Hannes Hirzel wrote:
Hannes Hirzel wrote:
Hannes Hirzel wrote:
My question applies to the Squeak implemenation of smallwiki.
The mime type isn't set for jpg, gif and wav files
To be more precise: The mime type is not set in the action class SWResourceEdit or one of its superclasse SWEditAction or SWAction.
Common mime types are (just strings) in the instance variable mimetype 'image/jpg' 'image/gif' 'audio/wav'
In the method renderFields of SWResourceEdit the following code snippet does not work correctly. html fileUploadWithCallback: #data:mime: The mime type returned is the empty string.
Is Mime supported in the VW-SmallWiki?
As I understand, the mimetype is set when you create a new Resource, but not, when you upload the data (or a new version). The default value is ''.
I will take a look if we can add this support, so the mimetype will be set correctly when you upload the data.
Regards Chris Burkert
squeak-dev@lists.squeakfoundation.org