Ticket #1244 (new defect)

Opened 1 year ago

Undefined index error in geshi.php when parsing code from the Blocks gadget

Reported by: metzenj@missouri.edu Assigned to: jaws-bugs@lists.jaws-project.com
Priority: normal Milestone: 0.9.0
Component: Other / Other bugs Version: 0.8.9
Severity: normal Keywords: gadgets, blocks, parse, quotes, languages
Cc:

Description

When putting code into the content (tested with PHP/terminal code) of a block using the blocks gadget, The following error occurs when viewing your site:

Undefined index: HARDQUOTE (and HARDESCAPE one line later) in /sites/muchancellorhydra/wwwdiversity/cms_tests/jaws/html/libraries/geshi/geshi.php

at around line 2402. These are the lines that seem to produce the error:

$string_attributes = ' style="' . $this->language_dataSTYLES?STRINGS?HARDQUOTE? . '"';

$escape_char_attributes = ' style="' . $this->language_dataSTYLES?ESCAPE_CHAR?HARDESCAPE? . '"';

Upon dumping out the contents of $this->language_data, it appears that these indecies are in the root of the language_data array, and not further down in the ESCAPE_CHAR?HARDQUOTE/ESCAPE? part of the array.

Also, the block text editor seems to incorrectly parse text with code in it, as when I load an existing block with PHP code in it, it seems to stick an extra emty code block at the top of the editor.

Here is the code that we used to produce the errors: [code='PHP'] for($i=0;$i<$intCount;++$i){

echo 'hello world';

} /code

[terminal]

This is my terminal code /terminal

Attachments


Add/Change #1244 (Undefined index error in geshi.php when parsing code from the Blocks gadget)




Change Properties
Action