Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
PHP: fdf_enum_values - Manual
[go: Go Back, main page]

PHP  
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
search for in the  
<fdf_createfdf_errno" width="11" height="7"/>
view the version of this page
Last updated: Sat, 21 Jan 2006

fdf_enum_values

(PHP 4 >= 4.3.0, PHP 5)

fdf_enum_values -- 各ドキュメントの値に対してユーザ定義関数をコールする

説明

bool fdf_enum_values ( resource fdfdoc, callback function [, mixed userdata] )

警告

この関数は、 現在のところ詳細な情報はありません。引数のリストのみが 記述されています。



add a note add a note User Contributed Notes
fdf_enum_values
ceo at l-i-e dot com
11-Jul-2003 03:13
If you need something like this in a pre 4.3 version, here is a rough hack I was working on before I realized I didn't need this after all.

       preg_match('/Fields\[(.*)\]/', $raw_pdf, $field_data);
       echo "Fields: ", htmlentities($field_data[1]), "<HR>\n";
       $field_data = $field_data[1];
       $key_value = explode(">><<", $field_data);
       $key_value[0] = substr($key_value[0], 2);
       $key_value[count($key_value) - 1] = substr($key_value[count($key_value) - 1], 0, -2);
       while (list(, $kv) = each($key_value)){
               list($key, $value) = explode("/V", $kv);
               $key = substr($key, 2);
               if ($key[0] == '('){
                       $key = substr($key, 1, -1);
               }
               if ($value[0] == '/'){
                       $value = substr($value, 1);
               }
               if ($value[0] == '('){
                       $value = substr($value, 1, -1);
               }
               echo "Key: $key Value: $value<BR>\n";
       }

The $raw_pdf can either be the $HTTP_RAW_POST_DATA before you write a submitted PDF, or it can just be the raw PDF data you would read from a PDF using, say:
$raw_pdf = implode("", file("/path/to/your/fdf/whatever.pdf"));

You'll probably need to tweak this to do something more interesting than just printing the stuff.

Hmmmm.  Think they'll throw me in jail for this post?  Oh well.

<fdf_createfdf_errno" width="11" height="7"/>
 Last updated: Sat, 21 Jan 2006
show source | credits | sitemap | contact | advertising | mirror sites 
Copyright © 2001-2006 The PHP Group
All rights reserved.
This mirror generously provided by: PacketBusiness, Inc.
Last updated: Tue May 2 07:16:05 2006 JST