Re: [greenstone-users] ImagePlug and Search UI Errors in 2.40

From Michael Dewsnip
DateMon, 14 Jul 2003 12:36:02 +1200
Subject Re: [greenstone-users] ImagePlug and Search UI Errors in 2.40
In-Reply-To (000001c348ec$d12265c0$0200a8c0-mrdsseattle)
Hi Jim,

Thanks for your e-mail. In response to your problems:

1. This is caused by an error in the pages containing a query box (in version
2.40 only). The problem is caused by calls to JavaScript functions that haven't
been defined. The "contains all/some" box is done differently (for some
reason), so it doesn't have this problem.

Based on what I've seen, everything still functions correctly (that is, changes
to the options selected cause the functionality to change appropriately), so
the problem is irritating but not fatal.

For us, there are two possible solutions: either define the missing function,
or remove the call to the function. Based on the evidence that the function
doesn't seem to be necessary, it seems likely that the call to the function
will be removed. However, I'll have to check this tomorrow with the person who
wrote this code. Unfortunately, a fix is likely to require recompiling the
source code.

The reason that this problem doesn't show up in the GLI is that the
HTML renderer used is just ignoring the problem - the problem is the same, but
the renderer never tells you about it.

2. This turns out to be exactly the same problem as the one Ben Dwyer reported
earlier - a missing ']' at the end of the screenicon assignment (line 287 in
ImagePlug.pm, version 2.40 only). This just goes to show the dangers of copy
and paste! You can fix this problem by adding the missing ']' to the line.

Regards,

Michael


Jim Trott wrote:

> Michael
>
> Here are two more strange things with 2.40: I am getting these errors when
> using the Library.exe version of 2.40 but I don't get it when I view the
> same collection through the GLI
>
> 1. SEARCH PAGE DIALOG BOXES
> On the Search page, when I try to change the value in the "Search for" and
> "In (language)" boxes, I get a Java Errors; however I don't get errors in
> the "Contain" (all/some) box. Here are the errors:
> Search for: gives an error on Line 94/95
> In: gives an error on Line 103
>
> It is interesting that I do not get this error when looking at the
> collection through GLI
>
> 2. IMAGE LIBRARY NOT DISPLAYED
> I am creating an image library using the ImagePlug (with the fix mentioned
> below).
> I am using the DocumentText format of:
> <center><table width=537 border=1><tr><td colspan=2
> align=center>[screenicon]</td></tr><tr><td>Caption:</td><td>
> <i>[dc.Description]</i> <br>(original [ImageWidth]x[ImageHeight] [ImageType]
> available)</td></tr><tr><td>Subject:</td><td>[dc.Subject and
> Keywords]</td></tr><tr><td>Creator:</td><td>
> [dc.Creator]</td></tr><tr><td>Rights:</td><td>[dc.Rights
> Management]</td></tr></table></center>
>
> When I view this through GLI, the screenicon (full image) displays just
> fine.
> When I view this through the Web Server (Library.exe) version, the
> screenicon (full image) does not display. I just get a 1 pixel line
>
> ABOUT MY COMPUTER:
> I am using Greenstone 2.40 Web Server
> I am using the GLI that came with Greenston 2.40(fixed with blanks removed
> from the BAT file)
> I am using IIS and Windows XP Professional
>
> Thanks for all your hard work!
>
> Jim Trott
> Knowledge Management Director
> Millennium Relief and Development Services
> email: jtrott@mrds.org
> web: www.mrds.org
>
>
> -----Original Message-----
> From: greenstone-users-bounces@list.scms.waikato.ac.nz
> [mailto:greenstone-users-bounces@list.scms.waikato.ac.nz] On Behalf Of
> Michael Dewsnip
> Sent: Thursday, July 10, 2003 4:09 PM
> To: Dwyer, Benjamin J
> Cc: greenstone-users@list.scms.waikato.ac.nz
> Subject: [greenstone-users] Re: ImagePlug Questions
>
> Hi Ben,
>
> Yes, you're quite right, that is a problem (in version 2.40 only). I've just
> made your fix to our code here, so the problem will be fixed for future
> releases.
>
> I'll CC this to the user's list, just in case other people have this
> problem.
>
> Thanks very much,
>
> Michael
>
> "Dwyer, Benjamin J" wrote:
>
> > Thankyou for your help,
> >
> > I believe there may be an error in version 2.40 of Greenstone. The
> > problem is in the ImagePlug file.
> >
> > I noticed in the examples of the OAI plugin demo at:
> >
> > http://www.nzdl.org/cgi-bin/library?e=p-000-00---0demooai--00-0-0-0pro
> > mp
> > t-10---4------0-1l--1-en-50---20-about---00001-001-1-0utfZz-8-0&a=d&cl=C
> > L2
> >
> > that when i viewed the collection in IE version 6.0 for Windows, that
> > all the thumbnail previews were squashed. This is because the height
> > of the thumbnail has not been specified. It is easily fixed by editing
> > the ImagePlug file, about half way down:
> >
> > $doc_obj->add_metadata ($section, "thumbicon", "<img
> > src=/gsdl/collect/gsarch/index/assoc/[assocfilepath]/[Thumb]
> > width=[ThumbWidth] height=[ThumbHeight>");
> >
> > there is a missing ']' after 'height=[ThumbHeight
> >
> > Regards
> >
> > Ben Dwyer
> >
> > -----Original Message-----
> > From: mdewsnip@cs.waikato.ac.nz [mailto:mdewsnip@cs.waikato.ac.nz]
> > Sent: Thursday, 10 July 2003 3:53 PM
> > To: Dwyer, Benjamin J
> > Cc: greenstone-users@list.scms.waikato.ac.nz
> > Subject: Re: ImagePlug Questions
> >
> > Hi Ben,
> >
> > In response to your questions:
> >
> > 1. The ImageMagick homepage is at http://www.imagemagick.org - you
> > might like to have a look around here first. To download ImageMagick
> > for Windows, try
> > ftp://ftp.imagemagick.org/pub/ImageMagick/binaries/ImageMagick-5.5.7-Q
> > 8-
> > windows-static.exe
> >
> > There are a few different Windows distributions available (differing
> > in terms of being statically/dynamically linked, and maximum bit
> > depth); the one shown above worked for me on a Windows 2000 machine.
> >
> > Once you've got it, just double-click to install. It is a standard
> > Windows installer, and has some helpful text at the start. It doesn't
> > matter where you install it. I recommend that you choose the "update
> > executable search path" option, since this handles setting the PATH
> > variable for you.
> >
> > Once it is finished installing, you should be all ready to go. Open up
> > a DOS prompt and check everything is working properly by typing
> > "convert" and "identify" (these are the two programs used by
> > ImagePlug). If these programs don't run, you'll have to manually add
> > their location to the PATH variable (let me know if you need help on
> > this). If they work, you should be OK to import files using ImagePlug.
> >
> > 2. Images are no different from any other file in terms of assigning
> > metadata via metadata.xml files. The Greenstone Librarian Interface
> > (which comes with Greenstone 2.40) makes metadata assignment much
> > easier, so I'd recommend you use this for assigning metadata to your
> > images.
> >
> > Hope this helps.
> >
> > - Michael
> >
> > ---------------------------------------------
> >
> > Hi,
> >
> > Just have a few questions regarding the ImgePlug plug-in.
> > 1) What is the procedure for downloading and setting up ImageMagick on
> > a Windows (XP) machine? I've searched the greenstone archives for the
> > answer but couldn't find it.
> > 2) Is there an easy way to add searchable and general metadata to
> > images using the ImagePlug plug-in?
> >
> > Regards,
> >
> > Ben Dwyer
>
> _______________________________________________
> greenstone-users mailing list greenstone-users@list.scms.waikato.ac.nz
> https://list.scms.waikato.ac.nz/mailman/listinfo/greenstone-users