|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #34811 fdf_get_value max size
Submitted: 2005-10-10 15:45 UTC Modified: 2008-07-11 21:12 UTC
Avg. Score:4.8 ± 0.7
Reproduced:7 of 7 (100.0%)
Same Version:2 (28.6%)
Same OS:1 (14.3%)
From: kc at netspirit dot ch Assigned: steinm (profile)
Status: Wont fix Package: FDF related
PHP Version: 4.4.0 OS: Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: kc at netspirit dot ch
New email:
PHP Version: OS:


 [2005-10-10 15:45 UTC] kc at netspirit dot ch
Problem getting value of PDF-Multiline-Fields if the value is loger than 256 chars.

found "ASInt32 nr, size = 256;" in "PHP_FUNCTION(fdf_get_value)" in "ext/fdf/fdf.c"

Reproduce code:

- go to:
- fill in the big field
- click on "Ausgabe-Optionen"

Expected result:
strText32 is of type string "hdsfj ....... sdfhjsd" 

Actual result:
strText32 is of type boolean "" 


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2005-10-10 15:55 UTC] kc at netspirit dot ch
code i used:

$pdformp = fopen("./test.dat", "w");
$fdf = fdf_open_string($HTTP_FDF_DATA);
while ($field = fdf_next_field_name($fdf, $field)) {
	echo "$field is of type " . gettype ( fdf_get_value ( $fdf, $field ) ) . " \"" . fdf_get_value ( $fdf, $field ) . "\" ";
	fwrite($pdformp, "$field=" . fdf_get_value ( $fdf, $field ) . "\n");
 [2005-10-11 14:09 UTC]
Assigned to the maintainer.
 [2006-10-11 21:33 UTC] randyharden at utah dot gov
I have a pdf file with a text field (FooField) that can exceed 255 characters in length.  I submit the form data using javascript command:
this.submitForm ("http://urlname/Submit_Form.php");

In Submit_Form.php....

$fdf = fdf_open_string(file_get_contents("php://input"));
$str = fdf_save_string($fdf);
//(the echo $str shows that all of the text string is their even if the string length exceeds 255 characters)
echo $str;

but... if I try to extract the value using:

$FooField=fdf_get_value($fdf, "FooField");

I get the correct results for strings up to 255 characters
but I get NULL as a result for strings > 255 chaaracters.
 [2008-07-11 21:12 UTC]
We are sorry, but we can not support PHP 4 related problems anymore.
Momentum is gathering for PHP 6, and we think supporting PHP 4 will
lead to a waste of resources which we want to put into getting PHP 6

PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Fri Dec 08 18:01:28 2023 UTC