php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #48069 corrupted form data after submit
Submitted: 2009-04-24 12:29 UTC Modified: 2009-04-24 17:19 UTC
From: andrej dot nagy at is-solutions dot sk Assigned:
Status: Not a bug Package: *General Issues
PHP Version: 5.2.9 OS: linux
Private report: No CVE-ID: None
 [2009-04-24 12:29 UTC] andrej dot nagy at is-solutions dot sk
Description:
------------
Sometimes if form is submitted, I get strange data on the server in php. It happens only about 3 times a day mostly using IE.
It seems that the problem might be in the encoding on the client, even though I set the corrent charset using "header('Content-Type: text/html; charset=UTF-8');" as soon as possible.
Sometimes I get some HTML tags in the field data e.g. (<table cellpadding= or <input type=)


Reproduce code:
---------------
form definition
<form action="..." method="post" class="search-form" name="reservation_form" id="reservation_form">

There are 2 buttons for submition:

<input type="submit" value="Book" class="submit_button" style="width:165px" />

<button type="submit" name="info_only" style="width:165px" value="1" class="submit_button with_value">Inform</button>



Expected result:
----------------
Correct form fields data.
objekt 15010 pouze v p??pad? ceny 838 CZK za pokoj a noc se sn?dan?

Actual result:
--------------
objekt 15010 pouze v p%u0159&#56353;d%u011B ceny 838 CZK za pokoj a noc se sn&#55585;n&#55456;/>

										<table cellpadding=


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-04-24 12:51 UTC] lbarnaud@php.net
This look like the data is already corrupted before it is sent to PHP. Check your javascript, check the HTML source of the page, etc.
 [2009-04-24 17:19 UTC] andrej dot nagy at is-solutions dot sk
Fields on the client are all empty when page is displayed.
Only user can type into fields.
There is no javascript behind submit.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Fri May 08 20:00:01 2026 UTC