How to remove a strange div named dp_swf_engine from an html page?

On my site , I recently found a weird new automatically created div. when I look at it in the development tools in chrome, I say:

<div id="dp_swf_engine" style="position: absolute; width: 1px; height: 1px;"><embed style="width: 1px; height: 1px;" type="application/x-shockwave-flash" src="http://www.ajaxcdn.org/swf.swf" width="1" height="1" id="_dp_swf_engine" name="_dp_swf_engine" bgcolor="#336699" quality="high" allowscriptaccess="always"></div> 

I really don't know what it is or where it comes from.

+4
source share
3 answers

I already had a similar problem and the div came from the chrome extension, check which extension can change your pages.

+8
source
  • Sometimes it will be automatically added from your web hosting server.
  • If you use external plugins, it will be from it
  • I could see that you are using Google fonts ... Try deleting and checking your site
  • You can run your site on a local server ...

To hide the DIV, try adding this css:

 <style type="text/css"> dp_swf_engine { display:none; } </style> 

thanks

+2
source

In the document ready event:

 var element = document.getElementById("dp_swf_engine"); document.body.removeChild(element) 

if your div is directly in your body else element, find its parent to call removeChildFunction ...

I hope to help!

0
source

Source: https://habr.com/ru/post/1500305/


All Articles