Bug #62636 [Csd->Nab]: PHP treated as HTML
| From: | aharvey@php.net | Date: | Mon, 23 Jul 2012 02:25:41 +0000 |
| Subject: | Bug #62636 [Csd->Nab]: PHP treated as HTML | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-172165@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=62636&edit=1
ID: 62636
Updated by: aharvey@php.net
Reported by: brandonskypimenta at gmail dot com
Summary: PHP treated as HTML
-Status: Closed
+Status: Not a bug
Type: Bug
Package: Scripting Engine problem
Operating System: Mac OS X
PHP Version: Irrelevant
Block user comment: N
Private report: N
Previous Comments:
------------------------------------------------------------------------
[2012-07-23 02:12:02] brandonskypimenta at gmail dot com
Oops! I forgot to add <?php at the beginning and ?> at the end. Sorry, not a bug.
------------------------------------------------------------------------
[2012-07-23 01:56:28] aharvey@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.
A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc. If the script requires a
database to demonstrate the issue, please make sure it creates
all necessary tables, stored procedures etc.
Please avoid embedding huge scripts into the report.
We actually need a self contained, small reproducable test script, not an unrelated piece of code.
:)
That said, this sounds very, very unlikely to be a PHP bug based on the description.
------------------------------------------------------------------------
[2012-07-23 01:48:48] brandonskypimenta at gmail dot com
Description:
------------
When running a script that is external (including it into another PHP file) opening that file will
result in that external PHP being rendered as HTML text on the screen.
Test script:
---------------
(This is not a test script. It is an attempt to make a MediaWiki extension.)
$wgExtensionCredits['validextensionclass'][] = array(
'path' => __FILE__,
'name' => 'Vote Pages',
'url' => 'https://www.mediawiki.org/wiki/Extension:VotePage',
'description' => 'Allows unregistered and registered users to vote
pages',
'version' => 1.0,
);
$rate = '<iframe frameborder="0" src="rate.html"
height="91">'
return $rate;
Expected result:
----------------
The external PHP script should have ran.
Actual result:
--------------
It displays the code and any HTML that has been used in the external PHP file will be displayed
instead.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=62636&edit=1