History log of /PHP-7.3/ext/standard/html.c (Results 76 – 100 of 255)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 4e198252 01-Jan-2012 Felipe Pena

- Year++


Revision tags: php-5.3.9RC4, php-5.4.0RC4, php-5.3.9RC3, php-5.4.0RC3
# aa5ce0b5 25-Nov-2011 Xinchen Hui

warning: suggest parentheses around && within ||


Revision tags: php-5.3.9RC2, php-5.4.0RC2, php-5.4.0RC1, php-5.3.9RC1, php-5.4.0beta2, php-5.4.0beta1
# 79bb4254 31-Aug-2011 Gustavo André dos Santos Lopes

- Less GCC warnings; code less readable, yay!
- Fixed html_tables.h generaration in 64-bit archs.
- Closes bug #55394 - Patch to suppress initialization warnings in html.c
#signed/unsigne

- Less GCC warnings; code less readable, yay!
- Fixed html_tables.h generaration in 64-bit archs.
- Closes bug #55394 - Patch to suppress initialization warnings in html.c
#signed/unsigned mismatches for another day
#regenerated tables on another commit

show more ...


# 1a9d43a8 31-Aug-2011 Gustavo André dos Santos Lopes

- Less GCC warnings; code less readable, yay!
- Fixed html_tables.h generaration in 64-bit archs.
- Closes bug #55394 - Patch to suppress initialization warnings in html.c
#signed/unsigne

- Less GCC warnings; code less readable, yay!
- Fixed html_tables.h generaration in 64-bit archs.
- Closes bug #55394 - Patch to suppress initialization warnings in html.c
#signed/unsigned mismatches for another day
#regenerated tables on another commit

show more ...


Revision tags: yaf-2.1.0, php-5.3.8, php-5.3.7, php-5.3.7RC5
# d5688cd1 10-Aug-2011 Xinchen Hui

Eliminated compiler's warnings


# 5540b64a 10-Aug-2011 Xinchen Hui

Eliminated compiler's warnings


# a61534ea 09-Aug-2011 Gustavo André dos Santos Lopes

- Elided unused argument in internal linkage function.


# 177645fd 09-Aug-2011 Gustavo André dos Santos Lopes

- Elided unused argument in internal linkage function.


Revision tags: php-5.4.0alpha3, php-5.3.7RC4, php-5.3.7RC3, php-5.4.0alpha2, php-5.3.7RC2, php-5.4.0alpha1, php-5.3.7RC1
# 547a9609 20-Mar-2011 Gustavo André dos Santos Lopes

- Fixed bug #54332 (trunk only, null pointer deref due to information loss on long to int conversion)
- Fixed some int* pointers being passed as size_t*.


Revision tags: php-5.3.6, php-5.3.6RC3, php-5.3.6RC2, php-5.3.6RC1
# 4a946a91 25-Jan-2011 Gustavo André dos Santos Lopes

- Fixed CHARSET_UNICODE_COMPAT (ISO-8859-1 is compatible in the relevant sense).
- Fixed usage of zend_multibyte_get_internal_encoding (its return cannot be
cast to char*).
- Change tes

- Fixed CHARSET_UNICODE_COMPAT (ISO-8859-1 is compatible in the relevant sense).
- Fixed usage of zend_multibyte_get_internal_encoding (its return cannot be
cast to char*).
- Change tests to reflect that charset detection now relies on
internal_encoding, not on current_internal_encoding.
NOTE: This fixes the changes in rev 306077, but it remains that that change
introduced a BC break. I assumed it was intentional

show more ...


Revision tags: php-5.2.17, php-5.3.5
# 927bf09c 01-Jan-2011 Felipe Pena

- Year++


# 0203cc3d 01-Jan-2011 Felipe Pena

- Year++


Revision tags: php-5.2.16, php-5.2.15, php-5.3.4
# 755c2cd0 08-Dec-2010 Dmitry Stogov

Removed compile time dependency from ext/mbstring


Revision tags: php-5.2.15RC2, php-5.3.4RC2, php-5.3.4RC1, php-5.2.15RC1, PHP_5_2_15RC1
# 71dfe80e 17-Nov-2010 Pierrick Charron

Remove unused variables


# e69b1ff2 27-Oct-2010 Gustavo André dos Santos Lopes

- Fixed bug #49687 (utf8_decode vulnerabilities and deficiencies in the number
of reported malformed sequences). (Gustavo)
#Made a public interface for get_next_char/utf-8 in trunk to use i

- Fixed bug #49687 (utf8_decode vulnerabilities and deficiencies in the number
of reported malformed sequences). (Gustavo)
#Made a public interface for get_next_char/utf-8 in trunk to use in utf8_decode.
#In PHP 5.3, trunk's get_next_char was copied to xml.c because 5.3's
#get_next_char is different and is not prepared to recover appropriately from
#errors.

show more ...


# 18fa045e 25-Oct-2010 Ilia Alshanetsky

Code cleanup & CS


# 20e2c5fc 24-Oct-2010 Gustavo André dos Santos Lopes

- Fixed uninitialized and 1 character short local variable.


# 91727cb8 24-Oct-2010 Gustavo André dos Santos Lopes

- Completed rewrite of html.c. Except for determine_charset, almost nothing
remains.
- Fixed bug on determine_charset that was preventing correct detection in
combination with interna

- Completed rewrite of html.c. Except for determine_charset, almost nothing
remains.
- Fixed bug on determine_charset that was preventing correct detection in
combination with internal mbstring encoding "none", "pass" or "auto".
- Added profiles for entity encode/decode for HTMl 4.01, XHTML 1.0, XML 1.0
and HTML 5. Added the constants ENT_HTML401, ENT_XML1, ENT_XHTML and
ENT_HTML5.
- htmlentities()/htmlspecialchars(), when told not to double encode, verify
the correctness of the existenting entities more thoroughly.
It is checked whether the numerical entity represents a valid unicode code
point (number is between 0 and 0x10FFFF). If using the flag ENT_DISALLOWED,
it is also checked whether that numerical entity is valid in selected
document. In HTML 4.01, all the numerical entities that represent a Unicode
code point (< U+10FFFFFF) are valid, but that's not the case with other
document types. If the entity is not valid, & is encoded to &amp;.
For named entities, the check is also more thorough. While before the only
check would be to determine if the entity was constituted by alphanumeric
characters, now it is checked whether that entity is necessarily defined for
the target document type. Otherwise, & is encoded to &amp;.
- For html_entity_decode(), only valid numerical and named entities (as defined
above for htmlentities()/htmlspecialchars() + !double_encode) are decoded.
But there is in this case one additional check. Entities that represent
non-SGML or otherwise invalid characters are not decoded. Note that, in
HTML5, U+000D is a valid literal character, but the entity &#x0D is not
valid and is therefore not decoded.
- The hash tables lazily created for decoding in html_entity_decode() that were
added recently were substituted by static hash tables. Instead of 1 hash
table per encoding, there's only one hash table per document type defined in
terms of unicode code points. This means that for charsets other than UTF-8
and ISO-8859-1, a conversion to unicode code points is necessary before
decoding.
- On the encoding side, the ad hoc ranges of entities of the translation
tables, which mapped (in general) non-unicode code points to HTML entities
were replaced by three-stage tables for HTML 4 and HTML 5. This mapping
tables are defined only in terms of unicode code points, so a conversion
is necessary for charsets other than UTF-8 and ISO-8859-1. Even so, the
multi-stage table is much faster than the previous method, by a factor
of 5; the conversion to unicode is a small penalty because it's just a
simple table lookup.
XML 1.0/htmlspecialchars() uses a simple table instead of a three-stage
table.
- Added the flag ENT_SUBSTITUTE, which makes htmlentities()/htmlspecialchars()
replace the invalid multibyte sequences with U+FFFD (UTF-8) or &#FFFD;
(other encodings).
- Added the flag ENT_DISALLOWED. Implements FR #52860. Characters that cannot
appear literally are replaced by U+FFFD (UTF-8) or &#FFFD; (otherwise).
An alternative implementation would be to encode those characters into
numerical entities, but that would only work in HTML 4.01 due to limitations
on the values of numerical entities in other document types. See also the
effects on htmlentities()/htmlspecialchars() with !double_encode above.

show more ...


# 30d6cc89 14-Oct-2010 Gustavo André dos Santos Lopes

- Fixed get_next_char(), used by htmlentities/htmlspecialchars, accepting
certain ill-formed UTF-8 sequences.


# bfcb754e 14-Oct-2010 Gustavo André dos Santos Lopes

- Fixed get_next_char(), used by htmlentities/htmlspecialchars, accepting
certain ill-formed UTF-8 sequences.


# 99b613cb 12-Oct-2010 Gustavo André dos Santos Lopes

- Added a 3rd parameter to get_html_translation_table. It now takes a charset
hint, like htmlentities et al.
- Fixed bug #49407 (get_html_translation_table doesn't handle UTF-8).
- Fixe

- Added a 3rd parameter to get_html_translation_table. It now takes a charset
hint, like htmlentities et al.
- Fixed bug #49407 (get_html_translation_table doesn't handle UTF-8).
- Fixed bug #25927 (get_html_translation_table calls the ' &#39; instead of
&#039;).
- Fixed tests for get_html_translation_table and unified the Windows and
non-Windows versions of the tests.

show more ...


# 4de6c3a9 12-Oct-2010 Gustavo André dos Santos Lopes

- Added a 3rd parameter to get_html_translation_table. It now takes a charset
hint, like htmlentities et al.
- Fixed bug #49407 (get_html_translation_table doesn't handle UTF-8).
- Fixe

- Added a 3rd parameter to get_html_translation_table. It now takes a charset
hint, like htmlentities et al.
- Fixed bug #49407 (get_html_translation_table doesn't handle UTF-8).
- Fixed bug #25927 (get_html_translation_table calls the ' &#39; instead of
&#039;).
- Fixed tests for get_html_translation_table and unified the Windows and
non-Windows versions of the tests.

show more ...


# f4a896c2 11-Oct-2010 Gustavo André dos Santos Lopes

- PHP uses a big endian representation when it converts the
code unit sequences to integers so as to store the entity
maps. Code in traverse_for_entities assumed little
endian. Fixe

- PHP uses a big endian representation when it converts the
code unit sequences to integers so as to store the entity
maps. Code in traverse_for_entities assumed little
endian. Fixed.
(in practice, due to the absence of unicode and entity
mappings for multi-byte encodings -- except UTF-8 --, this
doesn't matter, so the relevant code was commented out for
performance reasons).

show more ...


# 7aa43a8d 10-Oct-2010 Gustavo André dos Santos Lopes

- Revamp of the decoding portion of html.c.
- Dramatic improvements on the performance of html_entity_decode and htmlspecialchars_decode, as the
string is now traversed only once. Speedups

- Revamp of the decoding portion of html.c.
- Dramatic improvements on the performance of html_entity_decode and htmlspecialchars_decode, as the
string is now traversed only once. Speedups of 20 to 25 times with Windows release builds and a
~250 characters string (for 2nd and subsequent calls).
- Consistent behavior on html_entity_decode. For instance, the entity in "&&lt;" would be decoded,
but not "&&#233;". Not anymore. The code path for "basic" and non-basic entities is now mostly
shared.
- Code of html_entity_decode and htmlspecialchars_decode is now shared.
- [DOC] More consistent behavior of htmlspecialchars_decode. Instead of translating only &lt;, &gt;,
&amp;, &quot;, &#039; and &#39;, now e.g. &#34;, &apos;, &#0039;, &#x27;, etc. are also decoded.
- [DOC] Previous translation of unicode code points in numerical entities was seriously broken. When
the code points for some character were not the same in unicode and the target encoding, the
behavior could be an erroneous translation (e.g. 0x80-0xA0 in win-1252) or no translation at all.
Added unicode translation tables for all single-byte encodings. Entities are not translated for
multi-byte entities, except for ASCII characters whose code points are shared. We could add
the huge translation tables (several thousand elements) for those encodings in the future.
- Fixed numerical entities that after # had text accepted by strcol being accepted.
- Much more commented and well-structured code...
- Tests for get_html_translation_table()) are broken. I stared fixing the tests, but then I realized
it was completely helpless because get_html_translation_table() is broken by not handling
multi-byte characters correctly.

show more ...


# 4e2fd7ee 08-Oct-2010 Gustavo André dos Santos Lopes

- Fixed a typo in rev #304208 (24 instead of 34/'"').
- Improved the test bug53021.phpt to reflect other fixes in rev #304208.
- Updated NEWS to reflect other fixes in rev #304208.


1234567891011