2

We can embed images through HTML tags. For example, if I was bitterly writing equations through http://www.google.com instead of using LaTeX like I can on http://math.stackexchange.com, I could do this: x=\frac{d-c}{a-b}

With the HTML: <img src="https://chart.googleapis.com/chart?cht=tx&chl=x%3D%5Cfrac%7Bd-c%7D%7Ba-b%7D" alt="x=\frac{d-c}{a-b}">

But as you can see that's top aligned, which is not always desirable. So I'd like to use the align="middle" attribute. But I get this:

With the HTML: <img src="https://chart.googleapis.com/chart?cht=tx&chl=x%3D%5Cfrac%7Bd-c%7D%7Ba-b%7D" alt="x=\frac{d-c}{a-b}" align="middle">

Is there something I'm doing wrong or do we just not support that markup? Is there a Markdown alternative available to me?

2
  • 2
    this is a very specific case for having an image of a formula aligned when it's inline. couldn't you just present the image on a new line of it's own? or do you have any other justification for this request?
    – Tanner
    Commented Feb 10, 2017 at 13:45
  • 3
    Oh, yes, I suppose it is. I saw the question as what I wanted to see. It would still look very messy to have this formula displayed on the same line as the text, regardless of the vertical alignment. It should be on a separate line, horizontally centered, which we unfortunately do not support, either.
    – Cody Gray Mod
    Commented Feb 10, 2017 at 13:46

1 Answer 1

2

The align="middle" attribute isn't whitelisted for use here. To be safe, markdown just removes all HTML that contains anything that isn't whitelisted.

Basically, align="middle" isn't supported, so the element isn't rendered. There is no "pure markdown" alternative.

You must log in to answer this question.

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