html/ twitter-bootstrap/ iframe/ content-security-policy

i want using iframe in html but i got this error:

Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.

my code:

<iframe src="test.com" height="200" width="300" title="Iframe Example"></iframe>

how can i fix this error thanks inadvance

Iframe it has nothing to do with it, you have an inline script like <script>...</script> in the HTML code. Therefore you have opts:

暂无
暂无

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

Related Question Cordova error: Refused to execute inline script because it violates the following Content Security Policy directive Chrome extension policy error: Refused to execute inline event handler because it violates the following Content Security Policy directive Refused to execute inline script because it violates the following Content Security Policy directive: "default-src 'self'" I keep getting the error "Refused to execute inline event handler because it violates the following Content Security Policy directive Css inline style error in Chrome: “Refused to apply inline style because it violates the following Content Security Policy directive…” Html Error: Refused to load the script because it violates the following Content Security Policy directive Refused to load the script because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline' Refused to load scripts because it violates the following Content Security Policy directive Chrome Extension “Refused to load the script because it violates the following Content Security Policy directive” Refused to load the script because it violates the following Content-Security-Policy
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM