# When to Use Simple Embedding Code vs Advanced Embedding Code

### **Simple Embedding Code**

* Use this code when you need a quick, easy, and low-maintenance way to embed the form. It is ideal for situations where the website is simple, and there’s no need for advanced features like responsive design, security enhancements, or custom styling. It’s also a good option when you are working with a less technically skilled team or when integrating the form into a platform that restricts advanced coding.

{% code overflow="wrap" %}

```html
<html>
<body>
<iframe src="https://iwaspoisoned.com/widget/gov/46?id=dinesafe-test1&form=1"  height="800" width="100%" style="outline: none; border: none; max-width: 450px;"></iframe></body>
</html>

```

{% endcode %}

### **Advanced Embedding Code**

* Use this code when you require advanced responsive integration. It also offers some formatting advantages. As an end user you are welcome to experiment with both embedding options and see which works best for your use case.

```html
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Food Safety Reporting Widget</title>
    <style>
        .widget-container {
            width: 100%;
            height: 100vh;
            max-width: 450px;
            max-height: 650px;
            margin: 0 auto;
            display: flex;
            justify-content: center;
            align-items: center;
        }
        .widget-iframe {
            width: 100%;
            height: 100%;
            border: none;
        }
    </style>
</head>
<body>
    <div class="widget-container">
        <iframe 
            src="https://iwaspoisoned.com/widget/gov/46?id=dinesafe-test1&form=1" 
            class="widget-iframe"
            title="Food Safety Report Form"
            sandbox="allow-scripts allow-same-origin allow-forms"
            loading="lazy"
        >
            <p>Your browser does not support iframes. Please visit <a href="https://iwaspoisoned.com/widget/gov/46?id=dinesafe-test1&form=1">our reporting form</a> directly.</p>
        </iframe>
    </div>
    <script>
        window.addEventListener('message', function(event) {
            if (event.origin !== 'https://iwaspoisoned.com') return;
            // Handle any postMessage events from the iframe here
        }, false);
    </script>
</body>
</html>
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.dinesafe.com/dinesafe-knowledge-base/iwp-reporting-widget/embedding-the-widget/when-to-use-simple-embedding-code-vs-advanced-embedding-code.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
