OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



The artcile's PDF preview doesn't load

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 5:06 am

Hello!
We are running the 2.4.3v. OJS and today I've noticed that all articles doesn't shown in browser's window:

The PDF file you selected should load here if your Web browser has a PDF reader plug-in installed (for example, a recent version of Adobe Acrobat Reader).

If you would like more information about how to print, save, and work with PDFs, Highwire Press provides a helpful Frequently Asked Questions about PDFs.

Alternatively, you can download the PDF file directly to your computer, from where it can be opened using a PDF reader. To download the PDF, click the Download link above.

Very strange, cause about two weeks ago everything worked fine.
Tested with different browsers.
Waiting for solution.
Thank you!
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 8:11 am

Hi Garant,

Are you using the Google PDF viewer plugin?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 8:44 am

Hi!
I don't see that thus plugin would be installed in my browser.
Also IE8 doesn't have any of them.
Firstly I was informed from the library where we have many PC which are locked for browser updates...
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 8:50 am

Hi Garant,

That's an OJS plugin, not a browser-side plugin.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 8:54 am

Hi Alec!
Yes, it's google and somehow it was disabled.
Now I have it re-enabled but instead of error message there is blank area where pdf should be loaded
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 9:11 am

Hi Garant,

I didn't mean for you to turn it on -- just to confirm whether you were using it. If you weren't before, then please leave it disabled.

If your journal is open access, can you post or PM me a URL that demonstrates the problem?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 9:12 am

Hi Garant,

I didn't mean for you to turn it on -- just to confirm whether you were using it. If you weren't before, then please leave it disabled.

If your journal is open access, and it's not just the editor's preview area that's affected, can you post or PM me a public URL that demonstrates the problem?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 9:19 am

OK, now I will disable it and will send you PM
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 9:28 am

Hi Garant,

It looks like you've made modifications to plugins/blocks/fontSize/block.tpl to remove the font size tools, and that's causing a Javascript error ("ReferenceError: fontSize is not defined") because of the missing elements. Javascript errors can cause further Javascript on the page not to be executed. Can you try it again with the stock version of plugins/blocks/fontSize/block.tpl?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 9:34 am

Hi Alec!
I've downloaded the OJS archive and compared the file size, it's equal.
I've rewritten the block.tpl from plugins/blocks/fontSize but it doesn't make any sense...
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 9:44 am

Hi Garant,

There is a local modification somewhere that's breaking the font sizer. Looking further, it appears to be your article header template (templates/article/header.tpl). It refers to the fontController.js Javascript file in the wrong location.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 10:05 am

Hm... very strange... We haven't changed something in header for a long time...
Now I see that there JS are not found:
Code: Select all
   <script type="text/javascript" src="https://www3.mruni.eu/ojs/lib/pkp/js/general.js"></script>
   <script type="text/javascript" src="https://www3.mruni.eu/ojs/lib/pkp/js/tag-it.js"></script>
   <!-- Add javascript required for font sizer -->
   <script type="text/javascript" src="https://www3.mruni.eu/ojs/lib/pkp/js/jquery.cookie.js"></script>
   <script type="text/javascript" src="https://www3.mruni.eu/ojs/lib/pkp/js/fontController.js" ></script>


You think that they could cause a problem?
Last edited by Garant on Tue May 06, 2014 10:09 am, edited 1 time in total.
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 10:09 am

Hi Garant,

Your local modifications are resulting in a Javascript error, which is preventing further Javascript from running, including the PDF embed code. I'd suggest using a tool like Firebug for Firefox to review any Javascript errors, and if you're still having embedding problems once those are fixed, post back here.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Re: The artcile's PDF preview doesn't load

Postby Garant » Tue May 06, 2014 10:36 am

Very strange: ours modificated in the past header.tpl and newest from the archive shares the same include call for JS libraries load:
{include file="common/minifiedScripts.tpl"}
This .tpl wasn't modificated and it have these calls:
Code: Select all
<script type="text/javascript" src="{$baseUrl}/lib/pkp/js/functions/fontController.js"></script>
<script type="text/javascript" src="{$baseUrl}/lib/pkp/js/functions/general.js"></script>
<script type="text/javascript" src="{$baseUrl}/lib/pkp/js/functions/jqueryValidatorI18n.js"></script>

While the Firefox debug console states, that those JS files are not found and searches it in wrong place: without "functions" path folder
Garant
 
Posts: 228
Joined: Wed May 30, 2012 8:53 am

Re: The artcile's PDF preview doesn't load

Postby asmecher » Tue May 06, 2014 10:41 am

Hi Garant,

See above -- I think you're looking at the wrong template.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9214
Joined: Wed Aug 10, 2005 12:56 pm

Next

Return to OJS Technical Support

Who is online

Users browsing this forum: Bing [Bot], Google [Bot], Yahoo [Bot] and 4 guests