| 1 |
<?php |
<?php |
| 2 |
// $Id: geshifilter.pages.inc,v 1.11 2009/07/04 09:49:00 soxofaan Exp $ |
// $Id: geshifilter.pages.inc,v 1.12 2009/07/04 11:05:56 soxofaan Exp $ |
| 3 |
|
|
| 4 |
/** |
/** |
| 5 |
* @file |
* @file |
| 333 |
if ($inline_mode) { |
if ($inline_mode) { |
| 334 |
// inline source code mode |
// inline source code mode |
| 335 |
$geshi->set_header_type(GESHI_HEADER_NONE); |
$geshi->set_header_type(GESHI_HEADER_NONE); |
| 336 |
$source_code = '<span class="geshifilter"><code class="'. $geshi->overall_class .'">'. $geshi->parse_code() .'</code></span>'; |
// To make highlighting work we have to manually set a class on the code |
| 337 |
|
// element we will wrap the code in. |
| 338 |
|
// To counter a change between GeSHi version 1.0.7.22 and 1.0.8 (svn |
| 339 |
|
// commit 1610), we use both the language and overall_class for the class, |
| 340 |
|
// to mimic the 1.0.8 behavior, which is backward compatible. |
| 341 |
|
$code_class = "{$geshi->language} {$geshi->overall_class}"; |
| 342 |
|
$source_code = '<span class="geshifilter"><code class="'. $code_class .'">'. $geshi->parse_code() .'</code></span>'; |
| 343 |
} |
} |
| 344 |
else { |
else { |
| 345 |
// block source code mode |
// block source code mode |