6

Possible Duplicate:
Syntax highlighting language hints
Changes to syntax highlighting

I just asked a question on SO Facebook API scope and it's refusing to do a syntax highlight on my PHP code.

Is there anything extra required other than four spaces before each code line?

14

As announced in 2010 and specified on the Markdown Help Page, you have to either to tag with php or use one of the prettify language codes (<!-- language: lang-php -->) before the code.

E.g.

<!-- language: php -->

    // This is some PHP
    phpinfo();

https://github.com/google/code-prettify

| improve this answer | |
  • Adding <?php at the beginning break formatting. – jcubic Oct 26 '18 at 15:07

Not the answer you're looking for? Browse other questions tagged .