From: Chris Cormack Date: Sun, 8 May 2011 20:25:36 +0000 (+1200) Subject: Merge remote-tracking branch 'kc/new/bug_5449' into kcmaster X-Git-Tag: v3.06.00~586 X-Git-Url: http://koha-dev.rot13.org:8081/gitweb/?a=commitdiff_plain;h=9573f444fcd6f56b2c9248d6bc8d52525a62d518;hp=e064aba47e2047df9feeac985573784f6eff5912;p=srvgit Merge remote-tracking branch 'kc/new/bug_5449' into kcmaster --- diff --git a/offline_circ/process_koc.pl b/offline_circ/process_koc.pl index b22ae24f39..6c48ffb4ce 100755 --- a/offline_circ/process_koc.pl +++ b/offline_circ/process_koc.pl @@ -92,7 +92,7 @@ if ($completedJobID) { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ jobID: '$jobID' }"; + print '{"jobID":"' . $jobID . '"}'; exit 0; } elsif (defined $pid) { # child diff --git a/test/progressbarsubmit.pl b/test/progressbarsubmit.pl index 22b0a41f34..0982f58ca9 100755 --- a/test/progressbarsubmit.pl +++ b/test/progressbarsubmit.pl @@ -72,7 +72,7 @@ if ($completedJobID) { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ jobID: '$jobID' }"; + print '{"jobID":"' . $jobID . '"}'; exit 0; } elsif (defined $pid) { # if we get here, we're a child that has detached diff --git a/tools/background-job-progress.pl b/tools/background-job-progress.pl index db4d890497..380ad15c32 100755 --- a/tools/background-job-progress.pl +++ b/tools/background-job-progress.pl @@ -36,7 +36,7 @@ my ($auth_status, $sessionID) = check_cookie_auth($cookies{'CGISESSID'}->value, if ($auth_status ne "ok") { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ progress: 0 }"; + print '{"progress":"0"}'; exit 0; } @@ -54,4 +54,4 @@ if (defined $job) { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); # response will be sent back as JSON -print "{ progress: $reported_progress, job_size: $job_size, job_status: '$job_status' }"; +print '{"progress":"' . $reported_progress . '","job_size":"' . $job_size . '","job_status":"' . $job_status . '"}'; diff --git a/tools/batchMod.pl b/tools/batchMod.pl index d9a0b76911..4910dbd25b 100755 --- a/tools/batchMod.pl +++ b/tools/batchMod.pl @@ -563,7 +563,7 @@ sub put_in_background { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ jobID: '$jobID' }"; + print '{"jobID":"' . $jobID . '"}'; exit 0; } elsif (defined $pid) { # child diff --git a/tools/manage-marc-import.pl b/tools/manage-marc-import.pl index 61c0965ddb..3c43dabe1a 100755 --- a/tools/manage-marc-import.pl +++ b/tools/manage-marc-import.pl @@ -310,7 +310,7 @@ sub put_in_background { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ jobID: '$jobID' }"; + print '{"jobID":"' . $jobID . '"}'; exit 0; } elsif (defined $pid) { # child diff --git a/tools/stage-marc-import.pl b/tools/stage-marc-import.pl index 745a36adb8..0de73d46ec 100755 --- a/tools/stage-marc-import.pl +++ b/tools/stage-marc-import.pl @@ -108,7 +108,7 @@ if ($completedJobID) { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ jobID: '$jobID' }"; + print '{"jobID":"' . $jobID . '"}'; exit 0; } elsif (defined $pid) { # child diff --git a/tools/upload-file-progress.pl b/tools/upload-file-progress.pl index e3a643b4a4..c457dbb69d 100755 --- a/tools/upload-file-progress.pl +++ b/tools/upload-file-progress.pl @@ -35,7 +35,7 @@ my ($auth_status, $sessionID) = check_cookie_auth($cookies{'CGISESSID'}->value, if ($auth_status ne "ok") { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); - print "{ progress: 0 }"; + print '{"progress":"0"}'; exit 0; } @@ -44,4 +44,4 @@ my $reported_progress = C4::UploadedFile->upload_progress($sessionID); my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); # response will be sent back as JSON -print "{ progress: $reported_progress }"; +print '{"progress":"' . $reported_progress . '"}'; diff --git a/tools/upload-file.pl b/tools/upload-file.pl index 1f38d076eb..d520b4d7e7 100755 --- a/tools/upload-file.pl +++ b/tools/upload-file.pl @@ -80,5 +80,5 @@ sub send_reply { my $reply = CGI->new(""); print $reply->header(-type => 'text/html'); # response will be sent back as JSON - print "{ status: '$upload_status', fileid: '$fileid' }"; + print '{"status":"' . $upload_status . '","fileid":"' . $fileid . '"}'; }