# Custom html block

**URL:** <https://forums.losant.com/t/custom-html-block/2300>\
**Category:** Help\
**Tags:** dashboard\
**Created:** [October 21, 2019, 1:20pm UTC](https://forums.losant.com/t/custom-html-block/2300 "2019-10-21T13:20:38Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [October 21, 2019, 1:20pm UTC](https://forums.losant.com/t/custom-html-block/2300/1 "2019-10-21T13:20:38Z")

</div>

trying to test a custom google chart gauges, but I’m not getting any output.  
Any working dashboard I can see the code for?

---

<div class="post-metadata">

**Author:** ![JuliaKempf](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/juliakempf/32/2446_2.png) [@JuliaKempf](https://forums.losant.com/u/JuliaKempf)\
**Post date:** [October 21, 2019, 1:49pm UTC](https://forums.losant.com/t/custom-html-block/2300/2 "2019-10-21T13:49:07Z")

</div>

Hi @Lars_Andersson,

There are a few [working examples](https://docs.losant.com/dashboards/custom-html/#examples) in the [Custom HTML Block documentation](https://docs.losant.com/dashboards/custom-html/#custom-html).

Thanks!  
Julia

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [October 21, 2019, 1:51pm UTC](https://forums.losant.com/t/custom-html-block/2300/3 "2019-10-21T13:51:23Z")

</div>

Those are the ones I’ve tried copying in, but I’m not having any luck.

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [October 21, 2019, 1:52pm UTC](https://forums.losant.com/t/custom-html-block/2300/5 "2019-10-21T13:52:10Z")

</div>

See the last block in 5d1c077434fdb20009a83ed1

---

<div class="post-metadata">

**Author:** ![JuliaKempf](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/juliakempf/32/2446_2.png) [@JuliaKempf](https://forums.losant.com/u/JuliaKempf)\
**Post date:** [October 21, 2019, 4:03pm UTC](https://forums.losant.com/t/custom-html-block/2300/6 "2019-10-21T16:03:00Z")

</div>

Hi @Lars_Andersson,

I took a look at your block and it looks as though you did not remove the pre-filled configuration for this block, which is causing some problems as it is not included in the body. To remedy this to display correctly, you will either need to remove or include the prefilled configuration, or, at the minimum, remove this line from your code:

```auto
  function renderBlock(input) {
    document.getElementById('blockInput').innerHTML =
      JSON.stringify(input, undefined, 2);
  }

```

If you choose to include the `blockInput` in your HTML block, you would only need to add it to the body (I used `<div id="blockInput"></div>` and both are displayed):

 ![12%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/2/294fe3a290625f6908f31a32a48033d96ec7a823.png)

Thanks!  
Julia

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [October 21, 2019, 7:33pm UTC](https://forums.losant.com/t/custom-html-block/2300/8 "2019-10-21T19:33:06Z")

</div>

Got it ! Thanks for a quick response
