ID:               30603
 User updated by:  naderman at gmx dot de
 Reported By:      naderman at gmx dot de
-Status:           Open
+Status:           Closed
 Bug Type:         Unknown/Other Function
 Operating System: GNU/Linux (Debian)
 PHP Version:      4.3.9
 New Comment:

I noticed, this is not allowed anyway. I have to use " inside
attributes. So I close this now.


Previous Comments:
------------------------------------------------------------------------

[2004-10-28 19:43:11] naderman at gmx dot de

Description:
------------
I use a templating engine, and tried to put escaped quotes inside an
html attribute, but the result was quite different to what I expected,
the quotes in the end were missing. Afterwards I tried to do the same
with smarty, but the result was the same. I found out, that this only
happens inside quotes inside a html tag. This only happens with double
quotes. Single quotes are not removed, but I need to use double quotes
because my original intention was to use javascript inside
onmouseover.

I use the Debian PHP Package.

(This also happend with a self compiled version of PHP 5.0.2)

Reproduce code:
---------------
<?php
$var = 'This is a \\"test\\"';
eval(' ?><a title="<?php echo $var; ?>"><?php ');
?>

Expected result:
----------------
<a title="This is a \"test\"">

Actual result:
--------------
<a title="This is a \"test\>


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=30603&edit=1

Reply via email to