Whenever I try to use the "Enter PHP Code if true" extra '' are added to my code. For example a simple snippet like:
<?php
global $user;
if (in_array('Approved Role',$user->roles)) {
return TRUE;
} else {
return FALSE;
}
?>is changed to:
<?php
global $user;
if (in_array(''''Approved Role'''',$user->roles)) {
return TRUE;
} else {
return FALSE;
}
?>This happens whenever I try to use any PHP snippets - not just with the block visibility settings. I am using a plain text editor.
I've searched the Drupal issues, but didn't find any issues for this or any patch. Help please!
Comments
Comment #1
MsDetta commentedThought it might help if you have some additional information:
Drupal version 4.7.4
Server: Linux running Apache 1.3.37 (Unix)
PHP version 5.1.6
mySQL version 4.1.21-standard
I'm also getting array and array merge errors whenever I use an apostrophe (') in the help text area.
Comment #2
chx commentedComment #3
mot commentedNo activity since a long, long time. Closed.