Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 158 Stack Exchange communities.

What is meta?
Here's how it works:
  1. Any Stack Exchange user can ask a question
  2. The community provides support, votes on ideas, and reports bugs
  3. Your voice helps shape the way Stack Exchange operates

The prettifyier, assuming I used it correctly,

<pre class="prettyprint"><code>int main(void) { }</code></pre>

does not highlight text in the preview box when writing up a question/answer:

int main(void) { }

Is this intentional?

(I'll submit this question just to see if it works afterwards, heh.)

share|improve this question
Not sure I understand. Do you want to highlight the HTML or the C part? – Pëkka Jan 1 '11 at 12:26
Make sure your question is tagged with the correct language. Have you got an example of this? Plus syntax highlighting doesn't need to work here on meta. – ChrisF Jan 1 '11 at 12:40
@ChrisF: Well... a lot of people post GreaseMonkey scrips here on Meta. – uɐɯsO uɐɥʇɐN Jan 1 '11 at 17:47
@George - I forgot about that aspect. Just take out the word "need" from my comment then ;) – ChrisF Jan 1 '11 at 17:48
@ChrisF: "highlighting doesn't to work here on meta" - makes no sense :) – uɐɯsO uɐɥʇɐN Jan 1 '11 at 18:34
@George - OK, OK I give up - take "need to " out then ;) – ChrisF Jan 1 '11 at 18:38
up vote 3 down vote accepted

Indent your code by four spaces (or by clicking the { } button) to enable syntax highlighting. Entering the raw HTML will have the <pre> tag stripped because it does not conform to the strict permitted HTML rules.

share|improve this answer
<pre> will not be striped: it is in the list of allowed tabs (but no attributes allowed). – Richard Jul 31 '12 at 8:06
@Richard "You must enter the tags exactly as shown. Any deviation from this list (adding extra spaces, using single quote or no quotes, etc) means the tag will be stripped." (emphasis mine) - the OP of this question specifically mentioned that s/he was entering <pre class="prettyprint">, which would result in the entire tag getting stripped. – waiwai933 Jul 31 '12 at 8:12

You must log in to answer this question.

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