XML prolog not filtered correctly

hass - February 27, 2007 - 20:03
Project:Code Filter
Version:4.7.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:duplicate
Description

try out yourself with this example. the XML prolog closing with ?> and the filter thinks, this is the ending closing PHP tag, what is wrong. i'm using v1.14.2.4.

<?php
  $vars
['xml_prolog'] = <?xml version="1.0" encoding="utf-8"?>
'."\n";
?>

#1

hass - February 27, 2007 - 20:09

i tried with 1.14.2.6 and this bug is inside. Aside my code posted here is correctly displayed... looks like Drupal.org is using a different version!??

#2

fgm - July 12, 2007 - 07:10
Status:active» needs review

The typical fix for this situation is to split the ? and >, like this:

<?php
$vars['xml_prolog'] = '<?xml version="1.0" encoding="utf-8"?'.">\n";
?

#3

fgm - July 12, 2007 - 07:12

Oops missing closing brace:

<?php
$vars
['xml_prolog'] = '<?xml version="1.0" encoding="utf-8"?'.">\n";
?>

#4

JohnAlbin - August 17, 2007 - 22:37
Status:needs review» duplicate

See http://drupal.org/node/38047

 
 

Drupal is a registered trademark of Dries Buytaert.