# Embedding weatherwidget.io in topic?

**URL:** https://meta.discourse.org/t/embedding-weatherwidget-io-in-topic/301155
**Category:** Support
**Tags:** embedding
**Created:** [March 27, 2024, 1:12pm UTC](https://meta.discourse.org/t/embedding-weatherwidget-io-in-topic/301155 "2024-03-27T13:12:59Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![jordan-violet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jordan-violet/32/281428_2.png) [@jordan-violet](https://meta.discourse.org/u/jordan-violet)
#### Post date: [March 27, 2024, 1:12pm UTC](https://meta.discourse.org/t/embedding-weatherwidget-io-in-topic/301155/1 "2024-03-27T13:12:59Z")

</div>

I am trying to embed the code provided by [weatherwidget.io](http://weatherwidget.io) into a Discourse topic. I have users that will be attending a physical location for an event, and I wanted to provide the upcoming weather in that area. I want to embed this code, but I’m assuming scripts don’t work inline in the topic?

```plaintext
<a class="weatherwidget-io" href="https://forecast7.com/en/30d27n97d74/austin/?unit=us" data-label_1="dAustin, Texas" data-label_2="Weather" data-theme="original" >dAustin, Texas Weather</a>
<script>
!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src='https://weatherwidget.io/js/widget.min.js';fjs.parentNode.insertBefore(js,fjs);}}(document,'script','weatherwidget-io-js');
</script>

```

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [March 27, 2024, 1:30pm UTC](https://meta.discourse.org/t/embedding-weatherwidget-io-in-topic/301155/2 "2024-03-27T13:30:43Z")

</div>

You can do this with iframes(e.g.[Turning a topic into interactive fiction ;)](https://meta.discourse.org/t/turning-a-topic-into-interactive-fiction/87885)) but to adopt this code specifically as an optional addition to a post is going to require more work.

Perfect job imho for a freelancer if you have budget.  
#Marketplace

Alternatively look for another provider that does iframes:

[https://elfsight.com/weather-widget/iframe/](https://elfsight.com/weather-widget/iframe/) maybe? ( Cannot vouch)
