4

I have been trying to post an answer to this question:

Activate CSS3 animation when the content scrolls into view

I have read this but apparently I miss something probably obvious here because I am not able to post my answer. I get an error:

Your post appears to contain code that is not properly formatted as code...

I have pasted my answer here. As you can see, there are two blocks of codes, one with <script> tags and the other with $(window).load().

In an initial attempt, I simply formatted them with the {} icon which tabbed them by 4 spaces. Neither of them was appearing in the preview though, so I placed the <pre><code> tags but again the same error kept coming, being unable to submit the answer.

What is wrong with the code blocks?

UPDATE: After @Mat 's comments, and since there have been no answers regarding to this, I would like to make clear that partly it has been my fault that I have not properly understood that 8 spaces are necessary for code formatting within lists. Nevertheless, I change the question tag to 'bug' since I believe that it would be best for the user interface if the relevant code formatting button would recognize that the code is in a list and add the necessary spaces by itself rather than getting a validation error on posting.

4
  • 1
    That's a bit strange. Try removing the <pre><code> markup, and indent by 8 spaces (necessary for code within lists).
    – Mat
    Commented Apr 28, 2015 at 11:43
  • @Mat thanks for your comment, appreciated. This worked, that's what I was missing: didn't know that in lists 8 spaces were required. Although I would think that the relevant icon should format it appropriately anyway.
    – Wtower
    Commented Apr 28, 2015 at 11:55
  • 2
    @Mat Would you mind adding that as an answer for future reference? Commented Apr 28, 2015 at 14:37
  • 1
    @ASCIIThenANSI: that part is already documented here, but I'm wondering if this report isn't a bug - I don't see a reason for the post to have been denied using pre/code tags. So won't answer, to make it more likely that someone in the know has a look at it.
    – Mat
    Commented Apr 28, 2015 at 15:16

0

Browse other questions tagged .