0

Dear All,

I have searched pdf viewer in the internet. I have found some library and I have tried the code, but it still occured error. Some library is work but it must be on the internet connection.
I want to make the pdf viewer on my web in the local network. I need your help to complete it.

Thanks in advance.

2
Contributors
13
Replies
14
Views
5 Years
Discussion Span
Last Post by titusnainggolan
0

Please explain what tool you are using, and show us (part of) the code that is not working as expected. Do not forget to add what you want to achieve.

0

Thank you pritaeas.

I use vuzit 2.1 library.
the code is shown below.

 <?php
  include_once "VuzitPHP/lib/vuzit.php";

  Vuzit_Service::setPublicKey('YOUR_PUBLIC_API_KEY');
  Vuzit_Service::setPrivateKey('YOUR_PRIVATE_API_KEY');

  $doc = Vuzit_Document::upload("syntax.pdf");
  echo "Document id: " . $doc->getId();
  ?>

And the error occured is shown below.

Fatal error: Uncaught Vuzit_ClientException: [0]: CURL load failed: "couldn't connect to host" thrown in C:\xampp\htdocs\vuzit\VuzitPHP\lib\document.php on line 204

0

CURL load failed: "couldn't connect to host" thrown in C:\xampp\htdocs\vuzit\VuzitPHP\lib\document.php on line 204

What's on that line ?

0

I doubt my php is incompatible with the library.
Do you have any solution?
Maybe another library on php.

0

Are you sure your code can find syntax.pdf on the server ?

If it's just for viewing, IIRC Mozilla developed pdf.js

Edited by pritaeas

0

yes. syntax.pdf is available.

I just want to view pdf in web, but it could't be copied and downloaded.

Edited by titusnainggolan: grammar error

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.