0

Hi...

I have a problem to load a PDF file which is stored on another machine.I had loaded the PDF on the same machine using following PHP script.Here I had used a hyper link to load PDF.

<?php 
$file="first";
$pdfFile=$file.".pdf#page=1";
?>
<a href="<?php echo $pdfFile; ?>"  target="_blank" >  Click to view PDF</a>

This is working properly.But I had tried to access the PDF which is on another machine using IP address as follows

<?php 
$file="//192.x.x.x/e:/pdf/first";
$pdfFile=$file.".pdf#page=1";
?>

This script is not working...:(

Any body have any idea please help me.It is very urgent for my project.

3
Contributors
5
Replies
10
Views
6 Years
Discussion Span
Last Post by divyakrishnan
0

Try breaking the problem down into little pieces.

First type out the HTML by hand and make sure that the link is working. It's possible that your URL in the link is not exactly correct.

If you know the right URL, then it's possible you're not building the right URL with your PHP. In that case, print out your PHP variable and compare it to the correct URL.

Hope that helps!

0

I had tried using HTML as follows
<a href="192.x.x.x/d:/pdf/first.pdf" target="_blank" > Click to view PDF</a>
but it is not working..
What should I give IP address or computer name?

0

My problem is solved.I accessed it by installing a server.Using the the IP address.
Thank u for your support

This question has already been answered. 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.