ID: 32232 Updated by: [EMAIL PROTECTED] Reported By: crandym2003 at yahoo dot com -Status: Feedback +Status: No Feedback Bug Type: CGI related Operating System: Windows/Unix PHP Version: 4.3.10 New Comment:
No feedback was provided. The bug is being suspended because we assume that you are no longer experiencing the problem. If this is not the case and you are able to provide the information that was requested earlier, please do so and change the status of the bug back to "Open". Thank you. Previous Comments: ------------------------------------------------------------------------ [2005-03-08 23:29:21] [EMAIL PROTECTED] And FYI: I'd be very worried if "series_photo" ended up in $HTTP_POST_VARS (or $_POST, which you should use too) Uploaded file information usually goes into $_FILES.. ------------------------------------------------------------------------ [2005-03-08 23:23:37] [EMAIL PROTECTED] I can not reproduce this. With what browser(s) do you get this? Can you anyhow provide a short but COMPLETE script? (the one above does not have even a submit button, not to mention the fact that it's not even close being valid HTML) ------------------------------------------------------------------------ [2005-03-08 15:02:09] crandym2003 at yahoo dot com Description: ------------ When using the POST method in a form defined with enctype="multipart/form-data", a single defined hidden form element is lost between form named EditSeries when submit button posts form to submit_series.php. This only happens when text data entered into the TEXTAREA contains a special trademark character ™. I have seen this same bug before with other special characters. The form "submit_series.php" should get (4) form elements in the attached code which are: series_id, destination, series_desc, series_photo. Performing a dump_var $HTTP_SERVER_VAR at the beginnging of submit_series.php only shows (3) because the first form item "series_id" is somehow lost through CGI intrepretation. This doesn't happen unless data containing ™ is entered into the TEXTAREA box. The workaround is to place all hidden entities in the form after the TEXTAREA item or insert a extra hidden blank entity just above the series_id entity. This also does not happen if the enctype="multipart/form-data" is set to text entry only. In this case however, the form contains an input type=file so the multipart/form-data is necessary. Reproduce code: --------------- <form name=EditSeries action="submit_series.php" method="post" enctype="multipart/form-data"> <input type="hidden" name="series_id" value="123"> <input type="hidden" name="destination" value="$HTTP_SERVER_VARS['HTTP_REFERER']"> <TD width="85%"><TEXTAREA class=FormAdmin name=series_desc rows=8 wrap=virtual cols=66><?php print $series_desc ?></TEXTAREA></TD> <TD width="85%"><input class=FormAdmin type="file" size="56" name="series_photo" value=""></TD> Expected result: ---------------- When you run dump_vars($HTTP_SERVER_VARS) on the submit_series.php form and print them, there should be a total of (4) form items passed which are which are: series_id, destination, series_desc, series_photo. Actual result: -------------- When you run dump_vars($HTTP_SERVER_VARS) on the submit_series.php form and print them, there area a total of (3) form items passed which are which are: destination, series_desc, series_photo. Somehow, the first defined hidden entity series_id is lost and not defined in $HTTP_SERVER_VARS. This only happens when a special trademark character is entered as text data in the TEXTAREA box. If you move the location of the hidden items somewhere in the form "after" the TEXTAREA item, all elements are forwarded to the next page (i.e., this is a workaround) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=32232&edit=1