# Adding text between \<\> characters renders an empty post. (Example in this post)

**URL:** https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147
**Category:** Support
**Created:** [February 18, 2021, 6:23am UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147 "2021-02-18T06:23:51Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![fzngagan](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fzngagan/32/259349_2.png) [@fzngagan](https://meta.discourse.org/u/fzngagan)
#### Post date: [February 18, 2021, 6:23am UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/1 "2021-02-18T06:23:51Z")

</div>

Hidden text below:

```plaintext
<OnlyTwentyCharacters>

```

---

<div class="post-metadata">

### Author: ![riking](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/riking/32/170938_2.png) [@riking](https://meta.discourse.org/u/riking)
#### Post date: [February 18, 2021, 6:48am UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/2 "2021-02-18T06:48:07Z")

</div>

That turns into a disallowed HTML tag and is stripped out for safety. Not a bug.

Use &lt; if you want to start your post with a \< .

---

<div class="post-metadata">

### Author: ![fzngagan](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fzngagan/32/259349_2.png) [@fzngagan](https://meta.discourse.org/u/fzngagan)
#### Post date: [February 18, 2021, 6:59am UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/3 "2021-02-18T06:59:40Z")

</div>

Thanks for the explaination. I thought so too.

Is there a function in discourse which simply strips disallowed html ? The usecase is,

In the Custom Wizard plugin we want to disallow a user from submitting a post whose total number of characters excluding these stripped characters is less than the minimum character limit.

Also, now thinking about it, it is relevant to discourse too. Doesn’t it make sense to disallow submission if the rendered content is less than the min character limit? I know this is quite more complex than it sounds.

---

<div class="post-metadata">

### Author: ![neounix](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neounix/32/215617_2.png) [@neounix](https://meta.discourse.org/u/neounix)
#### Post date: [February 18, 2021, 7:36am UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/4 "2021-02-18T07:36:51Z")

</div>

When we have seen the same issue, we simply fence them with MD.

`<here is the good stuff>`

`<here is the sweet stuff>`

````plaintext
```<here is the good stuff>```

`<here is the sweet stuff>`

````

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [February 18, 2021, 7:42am UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/5 "2021-02-18T07:42:48Z")

</div>

> [@fzngagan](#):
>
> Doesn’t it make sense to disallow submission if the rendered content is less than the min character limit?

Cheaters gonna cheaṱ̴̢̧͔͓̘̫̫̣͕̻͉̩̯͙̝͈̞̼̻̱͉̘̘̮̜̝̬̻͕̯̜̦̹̜̐̐͊͒̉̄́͑̋̎́̋̃̀̆̕͜͜ͅ unicode is a big monster and there are plenty edge cases people can find to simulate blank posts that are not blank.

That is where moderation kicks in.

I am not sure if we have a hook you could use, but I guess you could prepend into `StrippedLengthValidator`.

I am half open to adding a hook there so you can do it without monkey patching.

---

<div class="post-metadata">

### Author: ![jomaxro](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jomaxro/32/126216_2.png) [@jomaxro](https://meta.discourse.org/u/jomaxro)
#### Post date: [February 21, 2021, 6:10pm UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/6 "2021-02-21T18:10:18Z")

</div>

Edited the OP as it’s getting flagged as empty by QAPage schema validation.

---

<div class="post-metadata">

### Author: ![fzngagan](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fzngagan/32/259349_2.png) [@fzngagan](https://meta.discourse.org/u/fzngagan)
#### Post date: [February 21, 2021, 7:07pm UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/7 "2021-02-21T19:07:17Z")

</div>

@sam

We were able to get this explaination across to someone who had raised their concern, also, we’re skipping model validations in the context of Custom Wizard plugin.

But in terms of core discourse, how about disallowing submission of a post if its cooked version is less than `min post length` ?

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [February 21, 2021, 11:34pm UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/8 "2021-02-21T23:34:55Z")

</div>

> [@fzngagan](#):
>
> But in terms of core discourse, how about disallowing submission of a post if its cooked version is less than `min post length` ?

I am not sure about this, it would not be intuitive to the user. There are going to be edge cases where raw is longer than cooked and it is legitimate.

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [March 23, 2021, 11:35pm UTC](https://meta.discourse.org/t/adding-text-between-characters-renders-an-empty-post-example-in-this-post/180147/9 "2021-03-23T23:35:54Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
