HTML tag allowed?


#1

Hi,

My tests reveal that only some html tag are accepted inside tag notes for example (ol, li…) but others completely break the API like

for example.

Is it expected behavior? Couldn’t you just ignore them instead of let it break the call? If this is intended, can we have a list of allowed tags?

Thanks a lot


Create Asana task from html page
#2

If you take a look at the preview doc we got for Rich Text it shows:

...restricted to the following tags:
<body>
<strong>
<em>
<u>
<code>
<ol>
<ul>
<li>
<a>

I think that’s probably the list you’re looking for.

As to your question about why other tags are not just ignored, that’s a good question!


#3

And \n for new lines


#4

Great thanks. So my remaining point is: should it really break everything when not using one of these tags?


#5

I’m not sure if it breaks or post the notes as plain text


#6

Rather than silently changing your data by stripping out unsupported tags or escaping them into regular text, the API will reject tags that have no equivalent in the Asana web product. We currently support the following tags:

  • <a>
  • <ol>
  • <ul>
  • <li>
  • <strong>
  • <em>
  • <code>
  • <u>

#7

Didn’t you forget <b> and <i> maybe?


#8

<b> is <strong>
and
<i> is <em>


#9

Ok about the visual result being the same, but my question remains if they are still accepted by the parser :slight_smile:


#10

Ah, good question!


#11

In the same spirit of “we won’t silently change your data” the API will not silently translate <b> and <i> tags to <strong> and <em>.