# How to bypass the 'Validation of Cookie Usage' error when using a SharinPix component in an Iframe?

## Description of the error

Traditionally, the Iframe syntax used to embed a SharinPix component was as follows:

```html
<apex:page standardController="Account" extensions="GetToken">    
    <iframe id="iframeId" class="sharinpix-iframe" src="https://app.sharinpix.com/?token={! SharinPixToken }"></iframe>    
</apex:page>
```

However, some devices encountered a cookie-based error as depicted in the image below:

![](https://751044238-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fi8tH1o5AHthxksYgF6ij%2Fuploads%2F3EDi1SGbzeIhCfuQBtKp%2Fimage%20\(1\).png?alt=media\&token=1c608d95-433d-4b5b-aac8-a1fc01bbea4c)

## Solution: Use of the postMessage method

To overcome this issue, SharinPix adopted the use of the **postMesssage** method. For more detailed information about how to use the postMessage method to bypass the error, click on the link that follows:

[Using a SharinPix component in an Iframe (Developer-oriented)](https://app.gitbook.com/s/5EvYRrLbUyvRh8o1jmMG/features/main-integration/using-a-sharinpix-component-in-an-iframe-developer-oriented)
