Doc #59716 [Fbk->NoF]: Missing output keys

From: Date: Sat, 07 Jan 2012 18:25:33 +0000
Subject: Doc #59716 [Fbk->NoF]: Missing output keys
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-7740@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=59716&edit=1 ID: 59716 Updated by: frozenfire@php.net Reported by: lowraider1 at gmail dot com Summary: Missing output keys -Status: Feedback +Status: No Feedback Type: Documentation Problem Package: APC Operating System: CentOS 5.5 PHP Version: 5.2.13 Assigned To: frozenfire Block user comment: N Private report: N Previous Comments: ------------------------------------------------------------------------ [2011-12-06 01:43:24] frozenfire@php.net I've just finished closing a bug related to this, which is that the "rate" key will not be available until *all* file uploads are completed. Could you please modify your script to only check those keys once all file transfers are completed? Specifically, you may need to check that the "done" key == 1. ------------------------------------------------------------------------ [2011-04-16 18:35:33] lowraider1 at gmail dot com Description: ------------ Hello, i am having a strange issue, the runtime manual states: apc.rfc1867 boolean RFC1867 File Upload Progress hook handler is only available if APC was compiled against PHP 5.2.0 or later. When enabled, any file uploads which includes a field called APC_UPLOAD_PROGRESS before the file field in an upload form will cause APC to automatically create an upload_key user cache entry where key is the value of the APC_UPLOAD_PROGRESS form entry. Note that the hidden field specified by APC_UPLOAD_PROGRESS must come before the file field, otherwise the upload progress will not work correctly. Note that the file upload tracking is not threadsafe at this point, so new uploads that happen while a previous one is still going will disable the tracking for the previous. Example #1 An apc.rfc1867 example <?php print_r(apc_fetch("upload_$_POST[APC_UPLOAD_PROGRESS]")); ?> The above example will output something similar to: Array ( [total] => 1142543 [current] => 1142543 [rate] => 1828068.8 [filename] => test [name] => file [temp_filename] => /tmp/php8F [cancel_upload] => 0 [done] => 1 ) The output i get is not the same with the one in the configuration runtime manual. I am missing "temp_filename", "cancel_upload", "rate" from the output array. Please tell me i am doing something wrong. Thanks Reproduce code: --------------- My code is the following: $status = apc_fetch('upload_'.$_GET['us']); echo json_encode($status); Expected result: ---------------- Array ( [total] => 1142543 [current] => 1142543 [rate] => 1828068.8 [filename] => test [name] => file [temp_filename] => /tmp/php8F [cancel_upload] => 0 [done] => 1 ) Actual result: -------------- it outputs: {"total":5239829,"current":4643259,"filename":"myarhive.zip","name":"fup","done":0,"start_time":1302992133.9842} ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=59716&edit=1

« previous php.doc.bugs (#7740) next »