The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

crobo17 (4) [Avatar] Offline
#1
Hi,

I'am having a problem with the viewing of the signature after the job is closed. Do you have to create a directory to store the .jpg file?


Or do you have to change this snippet of code.

<? <br /> require('db.php');
require('utils.php');
$data = file_get_contents('php://input');
$jobid = $_GET['jobid'];
$f = fopen("~/pathtowebsite/sigs/".$jobid.".jpg","w");//Do you change to the path of the hosted web application.

fwrite($f,$data);
fclose($f);
print(closeJob($_GET['jobid']));
?>
frank.ableson (75) [Avatar] Offline
#2
Re: Chapter 12. ( Viewing Signature after capture.)
$f = fopen("~/pathtowebsite/sigs/".$jobid.".jpg","w");//Do you change to the path of the hosted web application.

YES, you need to make sure that you have a legit path to a folder that can read/write the jpg files.
crobo17 (4) [Avatar] Offline
#3
Re: Chapter 12. ( Viewing Signature after capture.)
The folder have to have read/write permissions set on the server.

For example: www.mycompany.com/sigs. The sigs folder needs this permisson?
frank.ableson (75) [Avatar] Offline
#4
Re: Chapter 12. ( Viewing Signature after capture.)
yes, correct.
crobo17 (4) [Avatar] Offline
#5
Re: Chapter 12. ( Viewing Signature after capture.)
Thank you,
crobo17
crobo17 (4) [Avatar] Offline
#6
Re: Chapter 12. ( Viewing Signature after capture.)
I'am still having problems with obtaining the signature. I set the permission on the folder on the server to 777. Could it be a issue with the server?

When I try to retrieve the signature it brings me to a page not found message.
Do I have to change some code on the client side?

Thanks