Bug #79500 [NEW]: Duplicate function execution due to an HTML error

From: Date: Mon, 20 Apr 2020 12:15:41 +0000
Subject: Bug #79500 [NEW]: Duplicate function execution due to an HTML error
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-226684@lists.php.net to get a copy of this message
From:             dev at vraq dot fr
Operating system: All
PHP version:      7.4.5
Package:          Unknown/Other Function
Bug Type:         Bug
Bug description:Duplicate function execution due to an HTML error

Description:
------------
(Sorry if my English isn't always correct, I'm still struggling with the
language (and I'm using DeepL to help me))

Version of PHP where the bug was found: 7.4, 7.3, 7.2 (WAMP et
Infomaniak)

For some reason, this bug occurs when there is an HTML tag containing an
empty background-url style attribute :

<div style="background-image: url('');"></div>

This line generates, depending on the content of the defined function, a
double execution of the function.

Test script:
---------------
I made a small demonstration of the bug in a few lines:
https://test.vraq.fr/php_css_bug/

Expected result:
----------------
An entry must be present in the log file when the page is loaded.

Actual result:
--------------
Two entries were made in the file as if the function had been executed
twice.

I have the same problem with a mail function. Conversely, if you put an
ECHO in the function, it will be displayed only once.

-- 
Edit bug report at https://bugs.php.net/bug.php?id=79500&edit=1
-- 
Fix committed:                    https://bugs.php.net/fix.php?id=79500&r=fixed
Fixed in release:                 https://bugs.php.net/fix.php?id=79500&r=alreadyfixed
Need backtrace:                   https://bugs.php.net/fix.php?id=79500&r=needtrace
Need Reproduce Script:            https://bugs.php.net/fix.php?id=79500&r=needscript
Try newer version:                https://bugs.php.net/fix.php?id=79500&r=oldversion
Not developer issue:              https://bugs.php.net/fix.php?id=79500&r=support
Expected behavior:                https://bugs.php.net/fix.php?id=79500&r=notwrong
Not enough info:                  https://bugs.php.net/fix.php?id=79500&r=notenoughinfo
Submitted twice:                  https://bugs.php.net/fix.php?id=79500&r=submittedtwice
register_globals:                 https://bugs.php.net/fix.php?id=79500&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=79500&r=phptooold
Daylight Savings:                 https://bugs.php.net/fix.php?id=79500&r=dst
IIS Stability:                    https://bugs.php.net/fix.php?id=79500&r=isapi
Install GNU Sed:                  https://bugs.php.net/fix.php?id=79500&r=gnused
Floating point limitations:       https://bugs.php.net/fix.php?id=79500&r=float
No Zend Extensions:               https://bugs.php.net/fix.php?id=79500&r=nozend
MySQL Configuration Error:        https://bugs.php.net/fix.php?id=79500&r=mysqlcfg


Thread (2 messages)

« previous php.bugs (#226684) next »