Skip to content

Bug: Double use esc function with form_input and etc... #2443

Description

@MashinaMashina

Describe the bug
Code:

$data = [
	'name'  => 'field',
	'value' => set_value('field'),
];

echo form_input($data);
  1. Enter <h1>Hello</h1> to field and submit.
  2. In input you see "&lt;h1&gt;Hello&lt;/h1&gt;" instead your value
  3. If you again submit, you see "&amp;lt;h1&amp;gt;Hello&amp;lt;/h1&amp;gt;"
  4. After you can see "&amp;amp;amp;lt;h1&amp;amp;amp;gt;Hello&amp;amp;amp;lt;/h1&amp;amp;amp;gt;" and etc

Such behavior because CI4 use esc() in set_value() and in form_input (parse_form_attributes).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugVerified issues on the current code behavior or pull requests that will fix them

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions