Bug #71736 [NEW]: Conditional META HTTP-EQUIV output unconditionally
| From: | dlc dot usa at gmail dot com | Date: | Tue, 08 Mar 2016 01:51:42 +0000 |
| Subject: | Bug #71736 [NEW]: Conditional META HTTP-EQUIV output unconditionally | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-199660@lists.php.net to get a copy of this message | ||
From: dlc dot usa at gmail dot com
Operating system: CRUX 3.2
PHP version: 5.6.19
Package: Scripting Engine problem
Bug Type: Bug
Bug description:Conditional META HTTP-EQUIV output unconditionally
Description:
------------
name=php
version=5.6.19
release=1
source=(http://php.net/distributions/php-$version.tar.xz)
build () {
cd php-$version
local PHP_CONFIG="
--prefix=/usr --mandir=/usr/share/man \
--with-config-file-path=/etc/php \
--with-config-file-scan-dir=/etc/php/conf.d \
--with-zlib \
--with-pcre-regex=/usr \
--disable-static --disable-debug \
--without-sqlite3 --without-pdo-sqlite \
--without-pear"
local PHP_SHARED="
--enable-dba=shared --with-gdbm --with-db4 \
--with-bz2=shared \
--with-curl=shared \
--with-openssl=shared \
--enable-zip=shared \
--enable-mbstring=shared"
EXTENSION_DIR=/usr/lib/php/extensions \
./configure \
$PHP_CONFIG \
$PHP_SHARED \
--enable-cli \
--disable-cgi \
--with-readline
make
make -j1 INSTALL_ROOT=$PKG install
rm $PKG/usr/lib/php/extensions/*.a
ln -sf phar.phar $PKG/usr/bin/phar
sed -i '/^extension_dir/s|=.*$|= "/usr/lib/php/extensions"|'
php.ini-*
install -d $PKG/etc/php/conf.d
install -m 644 php.ini-* $PKG/etc/php
# order matters !
printf 'extension=%s\n' {zip,bz2,curl,openssl,dba,mbstring}.so \
> $PKG/etc/php/conf.d/extensions.ini
}
Test script:
---------------
Fails (works in 5.6.15); i.e., the engine does the echo/exit regardless
of variable values:
// If all is good and the user wants to go to the home page, do it
if ( $bsi == 'y' && $vgo == 'h' )
{ echo '<META HTTP-EQUIV=Refresh CONTENT="1;URL=DLC_Home.php?mwb=' .
$mwb . '">' ;
exit ;
} ?>
Changing the "META" above to "ME' . 'TA" as below works in both
releases:
// If all is good and the user wants to go to the home page, do it
if ( $bsi == 'y' && $vgo == 'h' )
{ echo '<ME' . 'TA HTTP-EQUIV=Refresh CONTENT="1;URL=DLC_Home.php?mwb='
. $mwb . '">' ;
exit ;
} ?>
Expected result:
----------------
The original code should behave in 5.6.19 as it does in 5.6.15.
Actual result:
--------------
The refresh to the HTTP-EQUIV URL occurs (but because the original page
was not properly processed due to the processing short-circuit, the
refreshed page is defective).
--
Edit bug report at https://bugs.php.net/bug.php?id=71736&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=71736&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=71736&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=71736&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=71736&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=71736&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=71736&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=71736&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=71736&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=71736&r=support
Expected behavior: https://bugs.php.net/fix.php?id=71736&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=71736&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=71736&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=71736&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=71736&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=71736&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=71736&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=71736&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=71736&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=71736&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=71736&r=mysqlcfg