OJS3: Problems with eLife Lens Article Viewer plugin

Hi @hannanhazari,

I am having the same issue with the dates being one day less.

Has this issue been fixed? if so, kindly share with me what is causing it and how to fix.

Thanks a lot!

Marlu

Hello, everyone!!

Our journal uses the Lens Galley to display articles, however, our markup and web development teams have found that some of the articles double the footnotes when they see the XML Jats on the viewer. I uploaded some screenshots we took about what happens.

Does anybody know why this happens? Is there a solution?

Double%20note Note%20within%20text Code Single%20note Footnote%20tag%20markup

Hi @abigail,

It looks like the Lens Viewer issue, not of the plugin itself. Unfortunately, I don’t know its code well, but maybe @Dulip_Withanage knows more.

Also, have you looked at JATS Parser Plugin? Although the footnotes are not supported at this time, I plan to add it in the next release, as well as an ability to work together with the Default theme (right now it works with the Immersion, Health Science, and Classic theme).

1 Like

HI @abigail,
the lens plugin is currently not enhanced but the main development, I put it into the lens goes directly this, GitHub - withanage/lensGalleyBits: OJS3 Plugin for JATS/BITS Galleys with enhanced LENS viewer
with is an enhanced version of the lensGalley.
If you could try the same jats xml with that and let me know, if the problem still exists.

1 Like

Hi @Vitaliy,

Thanks a lot. We’ve just heard of it, but we haven’t tried it. The markup and web development teams will check.

Hi @Dulip_Withanage,

Okay. Sounds great. We’ll check that and we’ll let you know what happens.

Thanks a lot, we appreciate it.

Hi @Dulip_Withanage

It’s me again. Our web development team has already tried the plugin you sent, but it still doesn’t work. They followed all the steps and they noticed that the versions which allow it are OJS 3.2 and OJS 3.1.2 (as shown in the screenshot). However, they also found out that the former is not listed on the PKP download page (as shown in the screenshot). Does it exist?

The version we are currently using in 3.1.1 Do you think the problem still exists because of that?pkp%20download github

Hi,

I am using OJS version 3.1.2.0, and the lens article viewer. But when I upload the images to it, he saves them to me in the delivery, but they are not displayed in the lens viewfinder. I get a 404 error.

Regards…

Hi @diegomejia07,

Can you include information on where you uploaded the images in OJS, and how you’re referencing them from your XML?

(Also filed here: Error images lens article viewer · Issue #40 · asmecher/lensGalley · GitHub)

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher ,

Load the images from the layout of the galley, as is normally done.

image

The url is not transformed, this is why it does not work. When you click on that URL, the image does not open and is not displayed in the lens gallery view.

Hi @diegomejia07,

What was the file’s exact filename on your computer (from which you uploaded it), and how is it referred to in the XML?

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher
The name of the file on my computer is 2216-0280-iee-37-01-e09-gf1.jpg and this is how I see it in the XML:

image

But in the viewer it shows the url

image

Does not convert

It would have to look something like this http://domain/journal/article/download/article_id/galley_id/artworkfile_id

Hi @diegomejia07,

What do you get for the following database query?

SELECT * FROM submission_files WHERE LOWER(original_file_name) = '2216-0280-iee-37-01-e09-gf1.jpg';

Hi @asmecher

image

Hi @diegomejia07,

Hmm, I can’t spot any problems there.

The way this is supposed to work is that OJS will fetch a list of dependent files (including the images you want to replace), then look through the XML for mentions of those files by upload filename. If it finds a match, it’ll replace the filename with the URL that fetches that file.

You can see this code in plugins/generic/lensGalley/LensGalleyPlugin.inc.php in the _getXMLContents function.

I would suggest adding some debug information (e.g. using error_log) to see what files are being fetched, and whether or not the filenames could be replaced.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher

This is de function
image

This is the error.log

image

Hi @asmecher,

Finally I could solve it by changing the calls to the xml arrays in the plugins / generic / lensGalley / LensGalleyPlugin.inc.php file, based on this change asmecher/lensGalley#36 add tests for text/xml mime type · asmecher/lensGalley@f708225 · GitHub

Thank you very much for the help.

Hi @diegomejia07,

Thanks for posting the solution! (I corrected the link to the commit – that is the correct one now, right?)

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,

Yes, this is the link correct to the commit.

Thank you very much for the help.